Risolto


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

circa 12 anni fa

Risolto


Factorial !
Calculate the factorial of a non-negative integer without using the built in function *factorial*

circa 12 anni fa

Risolto


It's race time! Write a faster function than the test suite call of unique().
Write a function to get unique elements of a vector faster than unique()! Input will be a vector (of integers or floating point ...

circa 12 anni fa

Risolto


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 ...

circa 12 anni fa

Risolto


convert matrix to single column
given any matrix, convert it to single column

circa 12 anni fa

Risolto


Max index of 3D array
Given a three dimensional array M(m,n,p) write a code that finds the three coordinates x,y,z of the Maximum value. Example ...

circa 12 anni fa

Risolto


Number of Circles in a Number
Given a number, return the number of closed 'circles' in the base 10 numerical representation. Note: the number 4 has no circ...

circa 12 anni fa

Risolto


Numbers with prime factors 2, 3 and 5.
Make a function which takes one positive integer n and returns a matrix with the numbers of the form (2^i)*(3^j)*(5^k) which are...

circa 12 anni fa

Risolto


is this number Munchhausen Narcissistic?
in this problem, simply return 1 if a supplied number is Munchhausen narcissistic or 0 if not. eg 153 is narcissistic but not...

circa 12 anni fa

Risolto


Back to basics 17 - white space
Covering some basic topics I haven't seen elsewhere on Cody. Remove the trailing white spaces from the input variable

circa 12 anni fa

Risolto


Volume of this donut
Given hole diameter a, and outermost diameter b, determine the volume y of the resulting donut.

circa 12 anni fa

Risolto


A matrix of extroverts
Now that the introverts have had their script, the extroverts spoke up (naturally!) and demanded one as well. You will be given...

circa 12 anni fa

Risolto


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

circa 12 anni fa

Risolto


Wind outward from the center ...
Create an n-by-n matrix with elements ranging from 1 to n^2 in a rectangular spiral pattern. Example if n = 5 : 21 ...

circa 12 anni fa

Risolto


Symmetry of vector
Determine whether the vector is symmetric or not (vector could be even or odd in length). For example: x = [1 2 3 3 2 1] ...

circa 12 anni fa

Risolto


Frobenius Norm
Write your own version of Frobenius Norm without using the 'norm' function.

circa 12 anni fa

Risolto


Better bullseye matrix
<http://www.mathworks.com/matlabcentral/cody/problems/18-bullseye-matrix Problem 18> asks to create a bullseye matrix like this:...

circa 12 anni fa

Risolto


subtract central cross
Given an n-by-n square matrix, where n is an odd number, return the matrix without the central row and the central column.

circa 12 anni fa

Risolto


Create an 'arrow-head" matrix
Write a function that when given an odd number, produces an arrow-head function pointing to the right. Examples n = 3 ...

circa 12 anni fa

Risolto


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 =...

circa 12 anni fa

Risolto


create a circulant matrix
create a circulant matrix

circa 12 anni fa

Risolto


The Dark Side of the Die
It is well-known that opposite sides of a classic hexahedral die add to 7. Given a vector of dice rolls, calculate the sum of th...

circa 12 anni fa

Risolto


Guess Cipher
Guess the formula to transform strings as follows: 'Hello World!' --> 'Ifmmp Xpsme!' 'Can I help you?' --> 'Dbo J ifmq zpv...

circa 12 anni fa

Risolto


What number has this problem?
This problem is added because it is problem number *???* in the "Community" problems section. <http://www.mathworks.de/matlab...

circa 12 anni fa

Risolto


Finding peaks
Find the peak values in the signal. The peak value is defined as the local maxima. For example, x= [1 12 3 2 7 0 3 1 19 7]; ...

circa 12 anni fa

Risolto


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...

circa 12 anni fa

Risolto


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

circa 12 anni fa

Risolto


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

circa 12 anni fa

Risolto


Determine if input is a perfect number
A <http://en.wikipedia.org/wiki/Perfect_number/ perfect number> occurs whent the sum of all divisors of a positive integer, exce...

circa 12 anni fa

Risolto


Nilpotent matrix
Check if matrix A is <http://mathworks.com/ nilpotent>.

circa 12 anni fa

Carica altro