Solved


Mirror, mirror on the wall, who is fairest of them all?
The Elo rating system was featured in the movie *The Social Network* during the <https://www.youtube.com/watch?v=BzZRr4KV59I/ al...

8 months ago

Solved


Find last non-zero in a given dimension
You are given a logical matrix *BW* _of any dimension_, and a dimension *dim*. You need to find the locations of the last non-ze...

8 months ago

Solved


Fractal: area and perimeter of Koch snowflake
Starting from an equilateral triangle with side 's', what is the area and perimeter of Koch snowflake at n'th recursive iteratio...

8 months ago

Solved


Repeat elements of a vector
Repeat each elements of a given vector according to their values. * x=[1,2,1,3] * y=[1,2,2,1,3,3,3]

8 months ago

Solved


Ratio between sums of prime and non-prime numbers
Write a function that calculates the ratio between the sum of the prime numbers lower or equal than x, and the sum of the non-pr...

8 months ago

Solved


Vector creation using colon operator
Create a vector y containing n uniformly spaced values between a and b, with a < b. Use the colon (:) operator.

8 months ago

Solved


Count integers in randomized vector that are multiples of a given number.
The mod() function We might all remember the days when we were taught to divide and then set the remainder aside if the numbers...

8 months ago

Solved


Return part of an array
Given a 5x5 array, return a 3x3 array that contains the cells that are not on the edge of the array: Given this array Return...

8 months ago

Solved


Summing the last column column
Given a matrix, return the sum of the last column of the array.

8 months ago

Solved


The twelve days of Christmas
Traditionally there are twelve days of Christmas to celebrate ("Twelvetide"), typically starting with Christmas Day (25 December...

8 months ago

Solved


How many days?!?
Christmas is coming earlier and earlier each year. Thanks to rampant commercialism and Christmas Creep, "The Twelve Days of Chr...

8 months ago

Solved


Calculate the Damerau-Levenshtein distance between two strings.
<http://www.mathworks.co.uk/matlabcentral/cody/problems/2303-compute-hamming-distances-between-each-pair-of-rows-from-two-input-...

8 months ago

Solved


longest common substring : Skipped character version
Two strings are given. Find the longest common substring between them. The substring characters need not be adjacent. They, howe...

8 months ago

Solved


Path calculation with polynomials
Let a vector x be the input to our function. 1. If a value of an input vector element x is lower than 0, set this value to 0....

8 months ago

Solved


Number Puzzle - 111

8 months ago

Solved


Write script that gives matrix like the following example:)
if x=2; y=[2 1; 1 1] if x=4; y=[4 3 2 1 3 3 2 1 0 2 2 1 0 0 1 1] if x=5; y=[5 4 3 2 ...

8 months ago

Solved


Find the square root of x
Determine the square root of x. For example square root of 4 is 2.

8 months ago

Solved


Add Odd and Subtract Even Numbers in an Array
For an input array, add all the odd values and subtract the even values. The final value is the output. E.g. input = [1 2 3 4 ...

8 months ago

Solved


Diophantine Equations (Inspired by Project Euler, problem 66)
Consider the quadratic Diophantine equation of the form: x^2 – Dy^2 = 1 When D=13, the minimal solution in x is 649^2 – 13...

9 months ago

Solved


Angle between two vectors
Given 2 pairs of _cartesian co-ordinates_, determine the angle between the 2 vectors formed by the _points_ and the _origin_. An...

9 months ago

Solved


Some tweaks in summation, Can you decode? :)
There are some tweaks in summation that you might observe via test suites Try if you can

9 months ago

Solved


Basics - not so easy division
Please make a function whcih divides x/y, but pay attention for some exceptions with NaN,0,Inf. Sometimes return "ERROR" instead...

9 months ago

Solved


Beat the test suite if you can :)
Solve this problem based on clues in the test suite.

9 months ago

Solved


Recursion at variable input
input of any length a =2 b =2 c =3 output = (a^b)^c = 64

9 months ago

Solved


Compute circular convolution
In signal processing, we usually encounter the circular convolution case. Compute it here using the two input sequences (denoted...

9 months ago

Solved


Insert certain elements into a vector.
We start with vector V. Some values W will be inserted into V, at positions U. Say, |V| contains |[1 2 3 4 5]| and |W| is |[0...

9 months ago

Solved


Ackermann's Function
Ackermann's Function is a recursive function that is not 'primitive recursive.' <http://en.wikipedia.org/wiki/Ackermann_fun...

9 months ago

Solved


Radial Zernike polynomials
Given an integer _n_ &ge; 0 and an integer _m_ &ge; 0, generate the <http://en.wikipedia.org/wiki/Zernike_polynomials radial Zer...

9 months ago

Solved


Hermite Polynomials
Return the _n_-th <http://en.wikipedia.org/wiki/Hermite_polynomials Hermite polynomial> of the physicists' type. Assume that ...

9 months ago

Solved


James Bond film count
Twenty-three James Bond films have been produced, in the years 1962, 1963, 1964, 1965, 1967, 1969, 1971, 1973, ... 197...

9 months ago

Load more