A résolu


Order of things - 2
This problem is closely related to <http://www.mathworks.nl/matlabcentral/cody/problems/2189-order-of-things-1 Problem 2189, Ord...

presque 5 ans il y a

A résolu


Order of things - 1
Let's assume you have a number of calculations to perform, that depend on each other. E.g. 'A' can be calculated, once the outco...

presque 5 ans il y a

A résolu


Bleed non-zeros to the right using REGEXP, and that sort of cheatcodess...
This one is quite similar to <http://www.mathworks.nl/matlabcentral/cody/problems/1998-bleed-non-zeros-to-the-right>. But thi...

presque 5 ans il y a

A résolu


Get the variable value from a string and generate sum
Get the variable value from a string. Example. x = 'A=10' y = 'B=20' Result = (x+y) Result = 30

presque 5 ans il y a

A résolu


Initialize a varible with an integer value from a another variable which is assigned with a character value.
Initialize a varible with an integer value from a another variable which is assigned with a character value. ex: Test = 'c'...

presque 5 ans il y a

A résolu


Create a "+" flag
Given two odd numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1...

presque 5 ans il y a

A résolu


Plotting Practice
Plot cos(x) vs x as shown in the figure below. Include the appropriate title, x-label, and y-label. Note, it is case sensitive. ...

presque 5 ans il y a

A résolu


Cross ("+") flag returns
Given two odd numbers, [m, n], return a matrix of size m x n which has all elements of the centre column and centre row set as 1...

presque 5 ans il y a

A résolu


Create the flag of Ramumbia
The little known nation of Ramumbia has a very simple flag. It is made up of vertical stripes, Red, Green, Blue, that are equall...

presque 5 ans il y a

A résolu


Scrabble Scores - 7
This problem is part of a set of problems that successively develop a more sophisticated Scrabble scoring routine. The point dis...

presque 5 ans il y a

A résolu


Scrabble Scores - 6
This problem is part of a set of problems that successively develop a more sophisticated Scrabble scoring routine. The point dis...

presque 5 ans il y a

A résolu


Scrabble Scores - 5
This problem is part of a set of problems that successively develop a more sophisticated Scrabble scoring routine. The point dis...

presque 5 ans il y a

A résolu


Scrabble Scores - 4
This problem is part of a set of problems that successively develop a more sophisticated Scrabble scoring routine. The point dis...

presque 5 ans il y a

A résolu


convert 2D array of ones and zeros to checkerboard array of [1,2] where the original array was ones and zero elsewhere
Given a 2D array of ones and zeros, generate an equivalent sized checkerboard array of ones and twos. The checkerboard pattern s...

presque 5 ans il y a

A résolu


Rule of mixtures (composites) - either bound
The <http://en.wikipedia.org/wiki/Rule_of_mixtures rule of mixtures> is used in the mechanical design of composite structures to...

presque 5 ans il y a

A résolu


Rule of mixtures (composites) - lower bound
The <http://en.wikipedia.org/wiki/Rule_of_mixtures rule of mixtures> is used in the mechanical design of composite structures to...

presque 5 ans il y a

A résolu


Dick Van Dyck?
* Not the celebrity, <http://en.wikipedia.org/wiki/Dick_Van_Dyke Dick Van Dyke>, * this problem relates to balanced strings of...

presque 5 ans il y a

A résolu


Write a cubic formula function
Create a function that will output the three roots of a cubic equation specified by the 4 coefficients listed as input. The outp...

presque 5 ans il y a

A résolu


Sales Tax

presque 5 ans il y a

A résolu


Get the combinations
Consider p,q = 2 vectors of same or different length. Get a Output Array which has all the possible combinations of Elements o...

presque 5 ans il y a

A résolu


FIFA World Cup 2014 : Offside
This problem is about offside rule in football (soccer). Input is a matrix with mostly zeros and a few 1, 2, 3 and 4s. A zer...

presque 5 ans il y a

A résolu


Create a function handle that reverses the input arguments of another function handle
Given a function that takes two input arguments and returns one output, create another function handle that performs the same op...

presque 5 ans il y a

A résolu


Expression or variable?
Test if arguments of the function are all variables (workspace variables names). Return 1 if yes, 0 if no. For example : ...

presque 5 ans il y a

A résolu


Triple function composition
Given three functions f,g and h, create the composed function y=f(g(h)). Example f = @(x) x+1 g = @(x) x/2 h = @(x) ...

presque 5 ans il y a

A résolu


The Google Interview: Two Eggs Problem
Consider the following problem, a popular Google interview question: A firm has invented a super-strong egg. For publicity pu...

presque 5 ans il y a

A résolu


Calculate time taken by light to reach earth surface
We know the time(seconds) taken by light to reach surface of earth. What if the distance varies yearly or source of light moves ...

presque 5 ans il y a

A résolu


Compute average gain for some bets.
Given a vector containg the odds of some events in decimal format (e.g., |odds=[1.3 2.5 1.5]| ) and a vector of the same dimensi...

presque 5 ans il y a

A résolu


Basic Monte Carlo Simulation
Input is a matrix including service time and probability of service time. Another input is a random number. Function should tran...

presque 5 ans il y a

A résolu


Area under standard normal curve

presque 5 ans il y a

A résolu


Decrypt Polybius
Decrypt Polybius square. Please refer to Problem 1150 Polybius Square. input [13 33 14 51] output 'cody'; input [23 0 26 33 4...

presque 5 ans il y a

Charger plus