已解决


Times 10
Try out this test problem first. Given the variable x as your input, multiply it by ten and put the result in y. Examples:...

3 years 前

已解决


Times 5
Try out this test problem first. Given the variable x as your input, multiply it by five and put the result in y. Examples...

3 years 前

已解决


solve for y that is half as much as three less than one tenth of x
function y = half(x) y = (x * .1); end

3 years 前

已解决


Calculate solution of given polynomial
For example, y=function([3 -2 -4]) In here, input vector indicate 3*x^2-2*x-4, y is solution of former equation. y=[1.5...

3 years 前

已解决


sum

3 years 前

已解决


Are all the three given point in the same line?
In this problem the input is the coordinate of the three points in a XY plane? P1(X1,Y1) P2(X2,Y2) P3(X3,Y3) how can...

3 years 前

已解决


free points
function y = your_fcn_name(x) y = x(1)+x(2); end

3 years 前

已解决


Distance walked 1D
Suppose you go from position 7 to 10 to 6 to 4. Then you have walked 9 units of distance, since 7 to 10 is 3 units, 10 to 6 is 4...

3 years 前

已解决


Right and wrong
Given a vector of lengths [a b c], determines whether a triangle with those sides lengths is a right triangle: <http://en.wikipe...

3 years 前

已解决


Proper Factors
Generate the proper factors of input integer x and return them in ascending order. For more information on proper factors, refer...

3 years 前

已解决


Opposite point of the earth, what is the antipodal of a point ?
Given two strings(lat and long) that represent the geographic coordinates of a point in the earth, you have to find out what is ...

3 years 前

已解决


Back to basics 12 - Input Arguments
Covering some basic topics I haven't seen elsewhere on Cody. Return a value equal to the number of input arguments to the fun...

3 years 前

已解决


Find the 9's Complement
Find the 9's complement of the given number. An example of how this works is <http://electrical4u.com/9s-complement-and-10s-c...

3 years 前

已解决


What's the missing interior angle?
I'm talking about polygons... The sum of the interior angles of a triangle is 180 degrees. The sum of the interior angles of a...

3 years 前

已解决


"Look and say" sequence
What's the next number in this sequence? * [0] * [1 0] * [1 1 1 0] * [3 1 1 0] * [1 3 2 1 1 0] This a variant on the w...

3 years 前

已解决


Kaprekar numbers
Test if the input is a Kaprekar number: <http://mathworld.wolfram.com/KaprekarNumber.html>. Return a logical true or false. ...

3 years 前

已解决


Smith numbers
Return true if the input is a Smith number in base ten. Otherwise, return false. Read about Smith numbers at http://en.wikipedia...

3 years 前

已解决


Mersenne Primes
A Mersenne prime is a prime number of the form M = 2^p - 1, where p is another prime number. For example, 31 is a Mersenne prim...

3 years 前

已解决


Sum of first n terms of a harmonic progression
Given inputs a, d and n, return the sum of the first n terms of the harmonic progression a, a/(1+d), a/(1+2d), a/(1+3d),....

3 years 前

已解决


Divisible by 10
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

3 years 前

已解决


Divisible by 6
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

3 years 前

已解决


Divisible by 4
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

3 years 前

已解决


Divisible by 3
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

3 years 前

已解决


Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...

3 years 前

已解决


Convert from Base 10 to base 5
Convert the input number from base 10 into base 5: for example: if a(in base 10)= 5 then a(in base 5)= 10

3 years 前

已解决


Index of a Rational number
The set of real numbers are infinite. They are so many that real numbers can't even be enumerated. However, unlike real numbers ...

3 years 前

已解决


Multiples of a Number in a Given Range
Given an integer factor _f_ and a range defined by _xlow_ and _xhigh_ inclusive, return a vector of the multiples of _f_ that fa...

3 years 前

已解决


Is it an Armstrong number?
An Armstrong number of three digits is an integer such that the sum of the cubes of its digits is equal to the number itself. Fo...

3 years 前

已解决


Integer Sequence - II : New Fibonacci
Crack the following Integer Sequence. (Hints : It has been obtained from original Fibonacci Sequence and all the terms are also ...

3 years 前

已解决


Fibonacci-Sum of Squares
Given the Fibonacci sequence defined by the following recursive relation, * F(n) = F(n-1) + F(n-2) * where F(1) = 1 and F(1)...

3 years 前

加载更多