Solved

Generate a vector like 1,2,2,3,3,3,4,4,4,4

Generate a vector like 1,2,2,3,3,3,4,4,4,4 So if n = 3, then return [1 2 2 3 3 3] And if n = 5, then return [1 2 2 3 3 3 4...

7 months ago

Solved

Make the vector [1 2 3 4 5 6 7 8 9 10]

In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

7 months ago

Solved

Finding Perfect Squares

Given a vector of numbers, return true if one of the numbers is a square of one of the numbers. Otherwise return false. Example...

7 months ago

Solved

Maximum value in a matrix

Find the maximum value in the given matrix. For example, if A = [1 2 3; 4 7 8; 0 9 1]; then the answer is 9.

7 months ago

Solved

Find the sum of all the numbers of the input vector

Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

7 months ago

Solved

Sum of series VII

What is the sum of the following sequence: Σ(km^k)/(k+m)! for k=1...n for different n and m?

7 months ago

Solved

Sum of series

a(n) = n^2 - (n-1)^2 find the summation of the series upto n i.e. a(1)+a(2)+...+a(n)

7 months ago

Solved

Sum of series VI

What is the sum of the following sequence: Σk⋅k! for k=1...n for different n?

7 months ago

Solved

Sum of series V

What is the sum of the following sequence: Σk(k+1) for k=1...n for different n?

7 months ago

Solved

Sum of series IV

What is the sum of the following sequence: Σ(-1)^(k+1) (2k-1)^2 for k=1...n for different n?

7 months ago

Solved

Sum of series III

What is the sum of the following sequence: Σ(2k-1)^3 for k=1...n for different n?

7 months ago

Solved

Sum of series II

What is the sum of the following sequence: Σ(2k-1)^2 for k=1...n for different n?

7 months ago

Solved

Sum of series I

What is the sum of the following sequence: Σ(2k-1) for k=1...n for different n?

7 months ago

Solved

Sum of diagonal of a square matrix

If x = [1 2 4; 3 4 5; 5 6 7] then y should be the sum of the diagonals of the matrix y = 1 + 4 + 7 = 12

7 months ago

Solved

Distance walked 1D

Suppose you go from position 7 to 10 to 6 to 4. Then you have walked 9 units of distance, since 7 to 10 is 3 units, 10 to 6 is 4...

7 months ago

Solved

Get the length of a given vector

Given a vector x, the output y should equal the length of x.

7 months ago

Solved

Pizza!

Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

7 months ago

Solved

Solve a System of Linear Equations

Example: If a system of linear equations in x₁ and x₂ is: 2x₁ + x₂ = 2 x₁ - 4 x₂ = 3 Then the coefficient matrix (A) is: 2 ...

7 months ago

Solved

Verify Law of Large Numbers

If a large number of fair N-sided dice are rolled, the average of the simulated rolls is likely to be close to the mean of 1,2,....

7 months ago

Solved

Find the Oldest Person in a Room

Given two input vectors: * |name| - user last names * |age| - corresponding age of the person Return the name of the ol...

7 months ago

Solved

Convert from Fahrenheit to Celsius

Given an input vector |F| containing temperature values in Fahrenheit, return an output vector |C| that contains the values in C...

7 months ago

Solved

Calculate Amount of Cake Frosting

Given two input variables r and h, which stand for the radius and height of a cake, calculate the surface area of the cake you n...

7 months ago

Solved

Times 2 - START HERE

Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

7 months ago