Risolto


Duplicate each element of a vector.
for an n-dimensional vector x, the function should return another vector 2n-dimension which each element is repeated twice. Ex...

quasi 8 anni fa

Risolto


Back to basics 10 - Max Float
Covering some basic topics I haven't seen elsewhere on Cody. Return the largest positive floating-point number MATLAB can han...

quasi 8 anni fa

Risolto


Love triangles
Given a vector of lengths [a b c], determines whether a triangle with non-zero area (in two-dimensional Euclidean space, smarty!...

quasi 8 anni fa

Risolto


Try 1.5.4: Celsius to Fahrenheit
Write a program to convert an input given in Celsius to Fahrenheit. Examples: Input celsiusValue = 100 Output fahrValu...

quasi 8 anni fa

Risolto


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

quasi 8 anni fa

Risolto


Find max
Find the maximum value of a given vector or matrix.

quasi 8 anni fa

Risolto


Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man? Give the name of that man, who, by popular believe, can ...

quasi 8 anni fa

Risolto


Omit columns averages from a matrix
Omit columns averages from a matrix. For example: A = 16 2 3 13 5 11 10 8 9 7 ...

quasi 8 anni fa

Risolto


Given an unsigned integer x, find the largest y by rearranging the bits in x
Given an unsigned integer x, find the largest y by rearranging the bits in x. Example: Input x = 10 Output y is 12 ...

quasi 8 anni fa

Risolto


Increment a number, given its digits
Take as input an array of digits (e.g. x = [1 2 3]) and output an array of digits that is that number "incremented" properly, (i...

quasi 8 anni fa

Risolto


Multiply a column by a row
* Given a column vector C and and a row vector R. * Output a matrix M. * Every column of M equals to C multiplied by correspon...

quasi 8 anni fa

Risolto


All capital?
Are all the letters in the input string capital letters? Examples: 'MNOP' -> 1 'MN0P' -> 0

quasi 8 anni fa

Risolto


Pandigital Multiples of 11 (based on Project Euler 491)
A "Pandigital number of order X" is one that contains all of the numbers from 0 to X, but with no leading zeroes. If X>9, the cy...

quasi 8 anni fa

Risolto


One track five lanes
Find the minimum number of lane changes necessary to cross the entire track without running into any obstacles <<http://www.a...

quasi 8 anni fa

Risolto


Arrange vector in ascending order
Arrange a given vector in ascending order. input = [4 5 1 2 9]; output = [1 2 4 5 9];

quasi 8 anni fa

Risolto


Say something funny
Say something funny, or not. Your solution will be (fully automatically and objectively) scored based on how clever or funny ...

quasi 8 anni fa

Risolto


Determine Whether an array is empty
Input a matrix x, output y is TRUE if x is empty, otherwise FALSE.

quasi 8 anni fa

Risolto


Ned's Queens
A tribute to Cody's five-year anniversary should also celebrate the people behind Cody, and in this particular case, our illustr...

quasi 8 anni fa

Risolto


Group-wise Euclidean distance
*Input*: * *x* —— An array of size *n-by-d*, where each row vector denotes a point in a d-dimensional space; * *g* —— A gro...

quasi 8 anni fa

Risolto


Parse me a Lisp
*Description* In Lisp and its variants, function calls are done using parenthesis where the first item in the parenthesis is ...

quasi 8 anni fa

Risolto


Recaman Sequence - III
I want to create a Recaman sequence where there is a "1" in the n-th position. So from which integer should I start the Recaman ...

quasi 8 anni fa

Risolto


Inscribed Pentagon? 2
Your function will be provided with the five vertices of a pentagon (p) as well as the center point (cp) and radius (r) of a cir...

quasi 8 anni fa

Risolto


Pair Primes
Let's define pair primes as follow; * *For 2 digits numbers:* 11 and 17 are pair primes because both of them are 2 digits pri...

quasi 8 anni fa

Risolto


Hexagonal numbers on a spiral matrix
Put hexagonal numbers in a ( m x m ) spiral matrix and return the sum of its diagonal elements. Formula of hexagonal numbers ...

quasi 8 anni fa

Risolto


Cache me Outside
The test suite includes a simple recursive Fibonacci sequence generator, but it's terribly inefficient. One simple method for im...

quasi 8 anni fa

Risolto


Is this a valid Tic Tac Toe State?
For the game of <https://en.wikipedia.org/wiki/Tic-tac-toe Tic Tac Toe> we will be storing the state of the game in a matrix M. ...

quasi 8 anni fa

Risolto


Digit concentration in Champernowne's constant
Consider the first 50 digits of Champernowne's constant 0.12345678910111213141516171819202122232425262728293... The...

quasi 8 anni fa

Risolto


An asteroid and a spacecraft
&#128640 Imagine a non-relativistic simple situation. Assume positions p0, p1, p2, and p3 are three dimensional Cartesian ...

quasi 8 anni fa

Risolto


Sums of Distinct Powers
You will be given three numbers: base, nstart, and nend. Write a MATLAB script that will compute the sum of a sequence of both ...

quasi 8 anni fa

Risolto


5th Time's a Charm
Write a function that will return the input value. However, your function must fail the first four times, only functioning prope...

quasi 8 anni fa

Carica altro