A résolu


Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z. Examples: Inputs x = 2, y = 4 Output z is 6 ...

plus de 8 ans il y a

A résolu


Find the relation
Take x as input and y as output. If x=1 y=3 If x=2 y=14 If x=3 y=39 If x=4 y=84 Based on this relation find giv...

plus de 8 ans il y a

A résolu


Convert degrees to radians
Given input in degrees, output to radians

plus de 8 ans il y a

A résolu


Log of a number
Write a script that will give the log of x as output.

plus de 8 ans il y a

A résolu


multiply an array by its position number
You have given an array. Multiply an array by its position number

plus de 8 ans il y a

A résolu


Give prime Numbers upto n
You are given a input number x; print all the prime numbers less than equal to x.

plus de 8 ans il y a

A résolu


Annual Salary
What is the annual salary of Mr. Cody if he works 40 hours a week and gets $x per hour and a yearly bonus of $2000? (Let, 50 wee...

plus de 8 ans il y a

A résolu


Generate the sum of Squares of the given number
|P(n) = 1^2 + 2^2 + ... + n^2| |P(1) = 1| |P(2) = 1 + 4 = 5;| |P(3) = 5 + 9 = 14;| |P(4) = 14 + 16 = 30;|

plus de 8 ans il y a

A résolu


Print true if
all elements are larger than 5 a=[1 3 5 8 6]; b=[6 6 6 6 6]; function(a) should be false, and function(b) will be tru...

plus de 8 ans il y a

A résolu


Is it column vector?
Is it column vector? Check vector for column vector without using iscolumn function.

plus de 8 ans il y a

A résolu


find a specific element from an matrix
Find the element from matrix which is in 2nd row and 3rd column.

plus de 8 ans il y a

A résolu


Add one raw in given matrix as shown in example
*Add one raw in given matrix as shown in example* A=[1 0;0 1]; X=[3 5]; Answer must be:[1 0; 0 1;3 5]

plus de 8 ans il y a

A résolu


Sum all integers from 1 to 2^x
Given a number x, your function must return the summation of all integers from 1 to 2^x.

plus de 8 ans il y a

A résolu


Can you reshape the matrix?
Given a matrix A, is it possible to reshape it into another matrix with the given number of rows?

plus de 8 ans il y a

A résolu


Determine if a row vector has NaN
Determine if a row vector x has NaN

plus de 8 ans il y a

A résolu


interesting center of magic matrix
output the centre of magic matrix of n input=7; output=25

plus de 8 ans il y a

A résolu


Simple return on investment
Assume you have some money and want to invest all your money to stock market. You randomly select a stock and invest all your mo...

plus de 8 ans il y a

A résolu


Find out sum of prime number till given number
Find out sum of prime number till given number Example, if number is 10, then answer must be 17.

plus de 8 ans il y a

A résolu


Weave two vectors into one
Weave the two given vectors into one as shown below. Example: If a = [1 1 1] b = [0 0 0] then y = [1 0 1 0 ...

plus de 8 ans il y a

A résolu


Find the sum of n squares
What is the sum of the squares of the first n integers?

plus de 8 ans il y a

A résolu


Freebies anyone? No!!!!
Feel free to copy paste all the tests and voila you solved the problem

plus de 8 ans il y a

A résolu


Matrix FUN
Given a Matrix M, find out the number of elements of matrix that are divisible by 3. M = [1 2 3;4 5 6;7 8 9]; ou...

plus de 8 ans il y a

A résolu


Find remainder when x is divided by 3
Find remainder when x is divided by 3

plus de 8 ans il y a

A résolu


Test if a number is numeric or not
Test if a number is numeric or not

plus de 8 ans il y a

A résolu


Vertically stack two vectors
Stack two vectors on top of each-other so that... if A = [1 5 3] and B = [8 6 4] then C = [1 5 3 ; 8 6 4]

plus de 8 ans il y a

A résolu


MATLAB Basic: rounding III
Do rounding towards minus infinity. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 8

plus de 8 ans il y a

A résolu


find whether it is prime or not
For a given number find if its prime

plus de 8 ans il y a

A résolu


Prime number removal
remove all prime numbers from the input e.g. input = 1 2 3 4 5 6 7 8 9 10 11 12 ...

plus de 8 ans il y a

A résolu


Replace odd number in given matrix by zero
Replace the odd numbers in a given matrix with zero. Example A = [ 17 24 1 8 15 23 5 7 ...

plus de 8 ans il y a

A résolu


square a vector-Given the variable x as your input, square it and put the result in y.
function y = (x)squared y = x; end

plus de 8 ans il y a

Charger plus