A résolu


Volume of a sphere given its surface area
You just measured its surface area, that is the input.

environ 11 ans il y a

A résolu


Flip the bit
Given an input character string (e.g. '1001'), return a character string with the bits flipped ('0110').

environ 11 ans il y a

A résolu


Find and replaces spaces from a input string with *
For a given input string str, find how many spaces are there in the string and replace those spaces with * e.g. str = 'this is ...

environ 11 ans il y a

A résolu


Create an index-powered vector
Given a input vector x, return y as index-powered vector as shown below. Example x = [2 3 6 9] then y should be [...

environ 11 ans il y a

A résolu


reverse string
input='rama' output='amar'

environ 11 ans il y a

A résolu


Relative ratio of "1" in binary number
Input(n) is positive integer number Output(r) is (number of "1" in binary input) / (number of bits). Example: * n=0; r=...

environ 11 ans il y a

A résolu


Roots
Find out the roots of a given polynomial equation.Given are the coefficients of the equation.

environ 11 ans il y a

A résolu


Count decimal digits of a number
* Given an integer number you have to return the number of its digits. * For example 248 has 3 digits and 1589 has 4 digits ...

environ 11 ans il y a

A résolu


sinus function
x is the abscissa. find the absolute value of cosine of -x and the same value with changed sign.

environ 11 ans il y a

A résolu


Back to basics - mean of corner elements of a matrix
Calculate the mean of corner elements of a matrix. e.g. a=[1 2 3; 4 5 6; 7 8 9;] Mean = (1+3+7+9)/4 = 5

environ 11 ans il y a

A résolu


Calculate the derivative of a polynomial
Example: in = [ 1 1 1 ] out = [ 2 1 ]

environ 11 ans il y a

A résolu


Bit Reversal
Given an unsigned integer _x_, convert it to binary with _n_ bits, reverse the order of the bits, and convert it back to an inte...

environ 11 ans il y a

A résolu


Convert Fahrenheit to Celsius
Calculate the Celsius temperature C given the Fahrenheit temperature F. Examples: Input F = 90 Output C is 32.22 I...

environ 11 ans il y a

A résolu


Computing wind chill
On a windy day, a temperature of 15 degrees may feel colder, perhaps 7 degrees. The formula below calculates the "wind chill," i...

environ 11 ans il y a

A résolu


Returning a "greater than" vector
Given a vector, v, return a new vector , vNew, containing only values > n. For example: v=[1 2 3 4 5 6] n=3 vNew =...

environ 11 ans il y a

A résolu


How many monitors are connected ?
How to obtain the numbers of monitors connected to your computer ?

environ 11 ans il y a

A résolu


Binary
Given a positive, integer n, create a function that returns the respective binary number in the form of a vector. Example: ...

environ 11 ans il y a

A résolu


Add a row of zeros on top of a matrix
Given a matrix, insert a row of zeros as the top row.

environ 11 ans il y a

A résolu


Matrix with different incremental runs
Given a vector of positive integers a (>=0); How does one create the matrix where the ith column contains the vector 1:a(i) poss...

environ 11 ans il y a

A résolu


Check if equal
Return true if all the elements of an nD array are equal, false otherwise.

environ 11 ans il y a

A résolu


Cody Matlab Version
What is the current Cody Matlab Release? *Output:* string *Examples:* '(R2012a)' or 'R2012a' Hint: We have mo...

environ 11 ans il y a

A résolu


Fahrenheit to Celsius using multiple statements
°C = (°F - 32) x 5/9 * Write a statement that assigns fractionalMultiplier with 5/9. * Write a second statement that assign...

environ 11 ans il y a

A résolu


Perfect Square or not
find Given input x is perfect square or not,if yes then output y=1.else y=0

environ 11 ans il y a

A résolu


Duplicate a character
Duplicate a character 'n' times. Example 1: str='a' n=5 output='aaaaa' Example 2: str='*' n=3 output='***'

environ 11 ans il y a

A résolu


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

environ 11 ans il y a

A résolu


Largest Twin Primes
<http://en.wikipedia.org/wiki/Twin_prime Twin primes> are primes p1, p2 = p1 + 2 such that both p1 and p2 are prime numbers. Giv...

environ 11 ans il y a

A résolu


Given a matrix, return the last eigen value
Given a matrix, return the first eigen value For example: x = magic(5) 17 24 1 8 15 23 5 7 14 ...

environ 11 ans il y a

A résolu


Area of rhombus
Calculate the rhombus area

environ 11 ans il y a

A résolu


Test if two numbers have the same digits
Given two integers _x1_ and _x2_, return |true| if the numbers written with no leading zeros contain the same digits. That is, t...

environ 11 ans il y a

A résolu


Generate pi using logarithm
Generate pi using logarithm

environ 11 ans il y a

Charger plus