Resuelto


We love vectorized solutions. Problem 1 : remove the row average.
Given a 2-d matrix, remove the row average from each row. Your solution MUST be vectorized. The solution will be tested for ac...

más de 7 años hace

Resuelto


convert the number to binary format & count digits
Convert the given number to the corresponding binary format and count the number of digits in that binary number

más de 7 años hace

Resuelto


Basics: counting digits of a number irrespective of the sign
publish the number of digits in any input integer example: -23---->2

más de 7 años hace

Resuelto


Solitaire Cipher
Implement the <http://en.wikipedia.org/wiki/Solitaire_(cipher) solitaire cipher>. Since this is from Wikipedia, I am capturin...

más de 7 años hace

Resuelto


Find all repeated numbers
For a given vector, find all numbers that repeated 2 times or more than 2 times. Example: A=[1 2 3 3 4 5 6 6 7] y=[3 ...

más de 7 años hace

Resuelto


Throwing Dice - Will You Be Eaten By The Dragon?
You and a dragon have agreed to let dice rolls determine whether it eats you or not. The dragon will roll a single die, of x ...

más de 7 años hace

Resuelto


Win all the time!
This is a 2-players game. One of them is your algorithm. Your algorithm must win in all games. In this game there are 3 rows...

más de 7 años hace

Resuelto


concatenate the elements
you should concatenate the elements of a matrix in one dimensional array, for example if the input is A = [1 2 3; 4 5 6; 7 ...

más de 7 años hace

Resuelto


String Delimination and Outputting
In this problem, take an incoming string and deliminate the string based on spaces. Output the first string in between the space...

más de 7 años hace

Resuelto


Automatic String Editing
In this function, you will take an incoming string, and output the same string with each character one letter later in the alpha...

más de 7 años hace

Resuelto


Separate even from odd numbers in a vector - without loops
*Without using loops*, rearrange a vector of integers such that the odd numbers appear at the beginning, and even numbers at the...

más de 7 años hace

Resuelto


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

más de 7 años hace

Resuelto


Minimum Maximum Sort Array
sort one array by put minimum value followed by maximum as follow a=[2 3 1 5] and the solution is y=[1 5 2 3 3 2 5 1];

más de 7 años hace

Resuelto


Fermat's Last Theorem - Fermat's conjecture
Fermat's Last Theorem (sometimes called Fermat's conjecture, especially in older texts) states that no three positive integers a...

más de 7 años hace

Resuelto


Fermat's last theorem - again
For a given integer n, express it as a sum of two squares if possible. Return empty matrix otherwise. Solution may not be unique...

más de 7 años hace

Resuelto


Write c^3 as sum of two squares a^2+b^2
write c^3 as sum of two squares a^2+b^2. a and b must be integer and greater than zero. For example 5^3 = 2^2 + 11^2 5...

más de 7 años hace

Resuelto


Draw a 'Z'.
Given _n_ as input, generate a n-by-n matrix like 'Z' by _0_ and _1_ . Example: n=5 ans= [1 1 1 1 1 0 0 0 1 ...

más de 7 años hace

Resuelto


Find NaNs in the matrix
Return 1s wherever there is a NaN in the input matrix

más de 7 años hace

Resuelto


Prime numbers between a , b.
Find all prime number between a & b. example: a=100 b=120 y= [101 103 107 109 113]

más de 7 años hace

Resuelto


surface areas of a cylinder
There are 3 inputs: option, radius and height. If option= '1', compute the lateral surface area of the cylinder, for option 2 ca...

más de 7 años hace

Resuelto


Capitalized string operations
Convert the input sentence to upper case and replace all vowels with an underscore ('_')

más de 7 años hace

Resuelto


Still more miles to go before I sleep
It's time for more odometer fun. Last problem, my car's odometer hit 56789. It's coming up on 111111 now, which (barring a maj...

más de 7 años hace

Resuelto


Calculate mean value of any pair in a vector.
Given a vector A, calculate the mean of 2 number in the vector one by one. example: input: A=[1, 5, 6, 8, 9, 15] output:...

más de 7 años hace

Resuelto


Outlier number!
Find a number which has maximum distance from the mean value of vector A. Example: A=[5 2 1 5 6 2 5 9] y=9

más de 7 años hace

Resuelto


'Absolute value'
Create a function called own_abs, which is the absolute number entered as the input return value.

más de 7 años hace

Resuelto


Try your chance!!!
There is a bomb in 3 cell! You must avoid to select the bomb. choose one of these cells and try your chance: 1 2 3 ?...

más de 7 años hace

Resuelto


Normie Function (2)
Another _Normie Function_ defined as _f(n)= f(n-1)+f(n-2)+f(n-3)_ , *when n>3* and _1_ , *when n<=3*. *Find the nth term of this...

más de 7 años hace

Resuelto


Product of all elements in an array
Compute the product of all elements in an array.

casi 8 años hace

Resuelto


generate capital english alphabets
Based on the numeric input 'n', generate the capital english alphabet starting from A till the english alphabet at the 'n'th pos...

casi 8 años hace

Resuelto


Repetition of matrices
*A is a bold matrix: [1 2 3; 4 5 6;7 8 9]* Given an integer 'n' , a matrix B exists such that has n copies of A in the row an...

casi 8 años hace

Cargar más