1 889 total contributions since 2012

R&D physicist, LEGO enthusiast

Solved

Creating a code via test suite :)

Given the test suites, create a code that would fit them :) *Clue: Pascal's Triangle

21 jours ago

Solved

Determinant of a 3x3 Matrix

Return the determinant of a 3x3 matrix. The built-in Matlab function det is not allowed.

21 jours ago

Solved

Rotate array 90 degrees

Rotate the given matrix by 90 degrees. Example, A = [1 2 3 ; 4 5 6 ] B = rotated(A) = [ 3 6; 2 5; 1 4 ]

21 jours ago

Solved

Rotate matrix by -90 degrees

Rotate a Matrix by -90 degrees Example: X = 1 2 3 4 5 6 7 8 9 output = 7 4 ...

21 jours ago

Solved

Vector Multiplication

Vector Multiplication of three matrix as shown in test cases.

21 jours ago

Solved

Sum of adjacent elements in a vector

Given a vector v, return a vector s containting the sum of every two adjacent elements in the vector. Every element s(i) cont...

21 jours ago

Solved

Remove the first, third and fifth rows of a matrix

Given a matrix x with at least five rows, return a matrix y that includes all rows of x except for th 1st, the 3rd and 5th. E...

21 jours ago

Solved

Relative points in 2D: problem 2

The 2D pose of a robot, with respect to a world coordinate frame {O}, is described by a 3x3 homogenous transform matrix T. A la...

3 mois ago

Solved

Relative points in 2D: problem 1

The 2D pose of a robot, with respect to a world coordinate frame {O}, is described by a 3x3 homogenous transform matrix T. A la...

3 mois ago

Solved

Relative pose in 2D: problem 2

We consider a world reference frame denoted by {0} which has its x-axis pointing east and its y-axis pointing north. There is a...

3 mois ago

Solved

Relative pose in 2D: problem 1

We consider a world reference frame denoted by {0} which has its x-axis pointing east and its y-axis pointing north. There is a...

3 mois ago

Solved

Check if a matrix is a palindrome in all directions

Check if a matrix is a palindrome both vertically and horizontally. You function will return *true* for |[1,2,1]| or |[2,7,2;...

3 mois ago

Solved

Find the nearest prime number

Happy 5th birthday, Cody! Since 5 is a prime number, let's have some fun looking for other prime numbers. Given a positive in...

3 mois ago

Solved

Removing rows from a matrix is easy - but what about inserting rows?

Assume A is a 5-by-5 matrix. A([2,4],:) = [] is a quick way to remove rows 2 and 4. Can you find a quick way to insert rows into...

6 mois ago

Solved

Transpose the Matrix

Transpose the given matrix, e.g. x=[a b;c d] transpose of x = [a c;b d]

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

7 mois ago

Solved

Pizza order

A pizza order by phone in diameter d1, pizza will be make only in diameter d2. Return the pizza pieces p should be make.(pizza ...

7 mois ago

Solved

Find the area of a triangle having vertices (A,B), (C,D), and (E,F)

Find the area of a triangle using if we have the three vertices of the triangle

7 mois ago

Solved

You never ask a lady her age

Instead you ask her to multiply her age by 10, then subtract any of the first nine multiples of 9 (9,18,...,81), and tell you th...

7 mois ago

Solved

Radiation Heat Transfer — View Factors (2)

View factors (aka configuration factors) are utilized in some radiation heat transfer models to estimate heat transfer rates bet...

12 mois ago

Solved

Convex Hull Capture

Imagine four points in uv that form a square. uv = [ ... 0,0; 0,2; 2,2; 2,0]; Now we have two more po...

12 mois ago

Solved

Under the sea: Snell's law & total internal reflection

<https://en.wikipedia.org/wiki/Snell's_law> When a light travels from one medium to another medium, depending on the refracti...

12 mois ago

Solved

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

12 mois ago

Solved

The answer to life the universe and everything

Write a function that gives the answer to life the universe and everything to every input except the input is 42. In this case t...

12 mois ago

Solved

The other half of the Fibonacci sequence

The <http://mathworld.wolfram.com/FibonacciNumber.html "Fibonacci sequence"> — F = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144,...

12 mois ago

Solved

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

12 mois ago