A résolu


Mastermind I: Solve all 1296 cases
<https://en.wikipedia.org/wiki/Mastermind_(board_game) Mastermind> is a code breaking logic puzzle. A pattern of 6 colors(values...

environ 9 ans il y a

A résolu


Shift elements of vector left
Shift elements of vector to the left. For ex. : Input_vec = [1 2 3 4 5] Output_vec = [2 3 4 5 1]

environ 9 ans il y a

A résolu


Replace Negative(-) by 0 and positive by 1
In a given Matrix Replace all element having *Negative sign with 0* and *Positive elements with 1* .

environ 9 ans il y a

A résolu


Rotate it!
Given a set of points, your aim is to rotate it by a given angle "theta" CCW (in 2d). The points are given in a matrix(x) of dim...

environ 9 ans il y a

A résolu


How brilliant are you?
A Brilliant number is defined as a number with two prime factors, both of which have the same number of digits. Some examples: ...

environ 9 ans il y a

A résolu


Speed of car travelling x meters in y seconds
What is the speed of a car if the car travelled x meters in y seconds? Supply the answer in m/s.

environ 9 ans il y a

A résolu


raise 1/3
Raise a number to 1/3 power.

environ 9 ans il y a

A résolu


Even or Odd
Write a function which can tell us if the given value x is odd or even. So if x is even return true and if x is odd return false...

environ 9 ans il y a

A résolu


Calculate the number of elements in a matrix.
Calculate the number of elements in a matrix.

environ 9 ans il y a

A résolu


Determine whether the number is multiple of 3 or not
Let a=6 and as 6 = 2*3 which means 6 is multiple of 3; return true if a is multiple of 3,otherwise false.

environ 9 ans il y a

A résolu


Find my secret function IV
We use the same secret function used on the past "Find my secret function ..." x=23 -------->> y=3 X=1000 ------->> 163

plus de 9 ans il y a

A résolu


Find my secret function III
only write a function gives you an outputs as expls: input: x=2 ------->>> Output: Y=1 input: x=100 ------->>> Output: Y=...

plus de 9 ans il y a

A résolu


Find my secret function II
If give my function a x value it will give me a y value, so find the secret of it: Examples: input x=23 ---- >>> output y=1...

plus de 9 ans il y a

A résolu


Find my secret function I
If give my function a x value it will give me a y value, so find the secret of it: Examples: input x=[2 5 6 8 9] ---- >>> o...

plus de 9 ans il y a

A résolu


Find the maxmum value of N*N Matrix
Input x=[1 2 3; 4 5 6; 7 8 9] output: y=9

plus de 9 ans il y a

A résolu


Matrix game: Winner takes all
Given a matrix A, return a new matrix of the same size in which the biggest element of each column in A takes 1, and 0 for all t...

plus de 9 ans il y a

A résolu


number of groups
In a classroom, *n* students work on a special project and the other students work in groups of five. If there are 18 students i...

plus de 9 ans il y a

A résolu


Determinants
Given a square matrix(A), find the determinant(d). For example: A = [1,3;4,5] d = 1*5-4*3 = -7

plus de 9 ans il y a

A résolu


Find the minimal value in N*N Matrix
Suppose that we have N by N matrix, we try to find the minimal value in that matrix. examples: Input A=[1 2 3 5 6;52 58 56 45...

plus de 9 ans il y a

A résolu


Is matlab fun?
Returns 'yes' no matter the input.

plus de 9 ans il y a

A résolu


Percentage profit:2
If you are selling at x dollar, you are facing r1% profit; what will be the selling price for making r2% profit?

plus de 9 ans il y a

A résolu


Percentage profit
If you are buying at x dollar, what will be the selling price for making the r% profit?

plus de 9 ans il y a

A résolu


Number of paths on a 3d grid
This problem is inspired by <https://www.mathworks.com/matlabcentral/cody/problems/1483-number-of-paths-on-a-grid>, which you mi...

plus de 9 ans il y a

A résolu


Find the optimal shape to bring the maximum product by a given perimeter
Find the optimal shape (with N sides) to bring the maximum product of the sides length, by a given perimeter. Example: Assumin...

plus de 9 ans il y a

A résolu


Volume Pillar
Calculate the volume of a pillar with radius l and heigth ar.

plus de 9 ans il y a

A résolu


without zeros
given an array with seros at the begining or at the end, you should get the output without these zeros: input = [zeros(5,...

plus de 9 ans il y a

A résolu


determine the sum of the squares
if x = 4, the solution will be: y = 1^2+2^2+3^2+4^2=1+4+9+16 = 30.

plus de 9 ans il y a

A résolu


Matrix Manipulation
Given an m*n matrix, see if a matrix contains any 0s in any row. if it contains 0 anywhere in any particular row, delete that ro...

plus de 9 ans il y a

A résolu


Get chain of consecutive characters
Write a function that will output a chain of consecutive characters, given 2 letters as input. It has to work backwards too. Exa...

plus de 9 ans il y a

A résolu


Find the binary code
Given a sinusoidal signal, create a function that returns the binary code of a quantized value. The function takes the bit lengt...

plus de 9 ans il y a

Charger plus