Solved


Hangman (strategy)
What is the best strategy in a <http://en.wikipedia.org/wiki/Hangman_(game) hangman> game? Your job is to device a strategy t...

1 year ago

Solved


Hangman (easy)
What is the best letter to start a <http://en.wikipedia.org/wiki/Hangman_(game) hangman> game with? You are given a cell arra...

1 year ago

Solved


Guess the number I'm thinking of (Part 1)
In this game you are competing against two other people to guess the number that I'm thinking of. I randomly choose an integer ...

1 year ago

Solved


Congruent
Given two numbers, check whether they are congruent to each other or not for a particular value N.

1 year ago

Solved


multiply by 12
multiply x by 12

1 year ago

Solved


raise x to the nth power
use basic math operators and a variable to solve the problem for a given variable n. (make sure "n" is the variable you use)

1 year ago

Solved


multiply by 5
multiply x by 5

1 year ago

Solved


The End of the World
given a date -- represent it in the Maya long count system. <https://en.wikipedia.org/wiki/Maya_calendar> <https://maya.nm...

1 year ago

Solved


Lost days
Given two dates in a particular format, calculate the difference between them.

1 year ago

Solved


Replace secondary diagonal elements of a square array
Replace all the secondary diagonal elements of the square array A with the number n Example: A = [1 2 3 4 5 6 ...

1 year ago

Solved


Accessing values in a cell
You are given c, which is a 1xN cell array, and a and b, which are each two 1xM vectors. Your job is to give the bth value in t...

1 year ago

Solved


most frequent character
Obtain the most frequent character. For example, s='balaram'; output='a'; If there is a tie between letters, return t...

1 year ago

Solved


De-primed
Write a function that will multiply every prime number in the array or matrix by two, leaving all other numbers the same, and re...

1 year ago

Solved


Evened up (or not)
You will be provided with an array or matrix that contains various numbers, in addition to an evening variable, e, set to 1 or 0...

1 year ago

Solved


Leap Year
According to Gregorian Calender(which is in use now, in many countries),decide whether a given year is a leap year or not. Give...

1 year ago

Solved


Datetime basics
Generate the datetime scalar representing the current date

1 year ago

Solved


Find the day for a date
Today's day and date will be given to you. By utilising that you need to find the day of the old date. (Date will be in DD/MM/YY...

1 year ago

Solved


Friday the 13th
According to superstition, lots of unpleasant stuff happens on Friday the 13th, so you might like to find the next occurence of ...

1 year ago

Solved


Day counter function
Write a function called day_counter that returns the number of Mondays that fell on the first day of the month in a given year b...

1 year ago

Solved


Count the days
Count the occurrence of a particular day (e.g. Monday) for a given duration.

1 year ago

Solved


Days until next NewYear ball drop
Given a date string in the form 'yyyy-mm-dd' or 'yyyy-mm-dd hh:mm:ss', calculate the number of *days* until the dropping of the ...

1 year ago

Solved


Friday or not
I love Friday. Please tell me whether the day is Friday. Dateformat is 'yyyy-mm-dd' or 'dd-mmm-yyyy' or 'mm/dd/yyyy'. Exa...

1 year ago

Solved


How long until the weekend?
Write a function a that takes a date vector as an input and returns the number of hours until the weekend begins. The beginning...

1 year ago

Solved


Special Relativity 101.
Special relativity states that the effective mass of an object varies as a function of its velocity. If *c* is the speed of ligh...

1 year ago

Solved


Who is using Cody?
Return your 'username' as char vector. Hint: no personal info are revealed, just use basic commands (not only Matlab).

1 year ago

Solved


matrix zigzag
Unfold a 2-D matrix to a 1-D array in zig-zag order, e.g., for matrix [ 1 2 3 ; 4 5 6 ; 7 8 9 ] the resulting 1-...

1 year ago

Solved


Bit calculation
Give me the count of numbers from 1 to n having their last two bits as 0. For example function y = ret_count(4) y = x...

1 year ago

Solved


Musical Note Interval 1 - Diatonic Scale
Assuming a simple diatonic C scale, calculate the interval (integer) between two notes (provided as strings). By applying number...

1 year ago

Solved


dir with recursive subdirectory search
Write a function that performs a recursive file search. The input and output format can be identical to the dir function. The ...

1 year ago

Solved


Shorten pathname
Given a pathname string, return a condensed version by replacing intermediate folders with '..'. *Example* If fullpat...

1 year ago

Load more