Solved


Calendar Matrix
Return a calendar matrix for the given values of month and year. Assume that Sunday is the first day of the week. The resulting ...

12 years ago

Solved


Path calculation with polynomials
Let a vector x be the input to our function. 1. If a value of an input vector element x is lower than 0, set this value to 0....

12 years ago

Solved


Test within tolerance
Given a vector of experimental data, D, and a vector of truth data, T, return FALSE if any +/- errors (D-T) are outside a given ...

12 years ago

Solved


Convert a vector into numbers
Suppose a vector x = [ 1 2 4 7] is given. You have to convert this vector into string number y = '1247'. Examples x = [ 1...

12 years ago

Solved


A Poker Hand
Texas Hold ‘Em is a classical card game. In this problem, we are concerned with determining the probability of attaining a certa...

12 years ago

Solved


Additive persistence
Inspired by Problem 2008 created by Ziko. In mathematics, the persistence of a number is the *number of times* one must apply...

12 years ago

Solved


is the number happy?
test is a given integer number is Happy of not? answer 1 if yes or 0 is no

12 years ago

Solved


Delete the rows in the middle
We will delete the rows in the middle and keep the first and the last rows. For example if input is [1 2 1 7 1 8 ...

12 years ago

Solved


Finger Counting
Just counting numbers using fingers. First all my ten fingers are closed. I will say 1 and open my one finger. Likewise for 6...

12 years ago

Solved


How many rectangles in a grid ?
How many rectangles are there in an m × n grid ? For example, if m=1 & n=2, we have 3 rectangles.

12 years ago

Solved


Best Fit RMS
Given a set of data as x and y, find the <http://en.wikipedia.org/wiki/Root_mean_square RMS> value between the data and its best...

12 years ago

Solved


Magic!
Check whether the input matrix is a normal magic square: <http://en.wikipedia.org/wiki/Magic_square> Output the logical va...

12 years ago

Solved


Is this group simply connected?
Given connectivity information about a graph, your job is to figure out if the graph is fully connected. You are given a list of...

12 years ago

Solved


Another colon problem
This is simple problem based on problems 555, 801, 1118, etc. Create an index vector from two input vectors. Example: ...

12 years ago

Solved


Fermat's Last Theorem - Fermat's conjecture
Fermat's Last Theorem (sometimes called Fermat's conjecture, especially in older texts) states that no three positive integers a...

12 years ago

Solved


Cell Source Index
Suppose that C is a cell array whose elements consist of row vectors of elements of the same type. For example, C could be a ce...

12 years ago

Solved


Convolution Power
Create the convolution-power vector from initial vector _x_ and power _n_. In other words, similar to the scalar case, raising ...

12 years ago

Solved


Numeric array to cell array of strings (easy)
Given a numeric array (A) and a 1xk cell array of strings (C), return a cell array (B) that is the same size as A and in which e...

12 years ago

Solved


Join Strings with Multiple Different Delimiters
The idea is to form the string S by interleaving the elements of a cell array of strings DELIMITER and another cell array of st...

12 years ago

Solved


Persistent Usage
This Challenge is to implement the Matlab Persistent variable capability. Given a sequence of Calls to a function return the ...

12 years ago

Solved


Number Persistence
A number's persistence is the number of steps required to reduce it to a single digit by multiplying all its digits to obtain a ...

12 years ago

Solved


THE CALCULATOR OF LOVE
In honor of Valentine's Day, program a love calculator that figures out the percentage of compatibility between two people using...

12 years ago

Solved


Decoding : Find the value
'u' in the function below is of type char or string and 'v' is of type int or double. function y = your_fcn_name( u, v) ...

12 years ago

Solved


Combinations without using nchoosek
You have to generate a matrix with all possible combinations of n elements *taken 2* at a time, *without using nchoosek(1:n,2)* ...

12 years ago

Solved


Justify the character string in center with proportional fonts
how to justify a string of character into center with proportional fonts? Example: x='justify string ' output is ' justif...

12 years ago

Solved


Set a Soroban Abacus
*Description* This problem is the inverse of <http://www.mathworks.com/matlabcentral/cody/problems/136-read-a-soroban-abacus ...

12 years ago

Solved


Read a Soroban Abacus
*Description* The Soroban is the name of the modern Japanese abacus. Information on reading a Soroban can be found <http://we...

12 years ago

Solved


Distance walked 3D
suppose you go from x-y-z coordinates [3,4,2] to [0,0,2] to [0,1,2] to [1,1,2], to [1,1,20] then you walked 25 units of distance...

12 years ago

Solved


Nearest Numbers
Given a row vector of numbers, find the indices of the two nearest numbers. Examples: [index1 index2] = nearestNumbers([2 5 3...

12 years ago

Solved


Polybius Square
Given a string, calculate the coordinates. Input will be always in lowercase. If string is a sentence then use 0 (zero) to indic...

12 years ago

Load more