已解决


Sum of the Multiplication of Vectors
Given the vectors x and y as input, multiply the vectors and return the summation of its elements. Example: x = [1 2 ...

4 years 前

已解决


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

4 years 前

已解决


Alternating sum
Given vector x, calculate the alternating sum y = x(1) - x(2) + x(3) - x(4) + ...

4 years 前

已解决


Replace multiples of 5 with NaN
It is required to replace all values in a vector that are multiples of 5 with NaN. Example: input: x = [1 2 5 12 10 7] ...

4 years 前

已解决


Positive Infinity
Round the array a towards positive infinity

4 years 前

已解决


Replace every 3rd element in a vector with 4
x is a vector of undetermined length You are to replace every 3rd element with the number 4, example: x = [11 23 34 43 2 3...

4 years 前

已解决


Equal to their cube
Tell me three real numbers that are equal to their cubes?

4 years 前

已解决


Find the dimensions of a matrix
Just find the number of columns of the given matrix. Example x = [1 2 3 4 5 6] y = 2

4 years 前

已解决


Make one big string out of two smaller strings
If you have two small strings, like 'a' and 'b', return them put together like 'ab'. 'a' and 'b' => 'ab' For extra ...

4 years 前

已解决


Add two numbers
Calculate the sum of two numbers. Example input = [2 3] output = 5

4 years 前

已解决


length of a vector
Find twice the length of a given vector.

4 years 前

已解决


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

4 years 前

已解决


Sorted highest to lowest?
Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

4 years 前

已解决


Is the input divisible by 3?
Return true if the input is divisible by 3 and false if not.

4 years 前

已解决


reverse string
input='rama' output='amar'

4 years 前

已解决


kmph to mps
convert kilometer per hour to meter per second

4 years 前

已解决


Find the hypotenuse
Given a and b (the two sides of a right-triangle), find c, the hypotenuse.

4 years 前

已解决


Divide by 4
Given the variable x as your input, divide it by four and put the result in y.

4 years 前

已解决


Create an index-powered vector
Given a input vector x, return y as index-powered vector as shown below. Example x = [2 3 6 9] then y should be [...

4 years 前

已解决


Create a vector whose elements depend on the previous element
The idea is to create a vector A whose elements depend on the previous element : *A(i+1) = 2*A(i)+1* *2 Inputs*: - A : The...

4 years 前

已回答
Counting the number of digits
no_of_digits = numel(num2str(abs(A)));

4 years 前 | 0

已解决


Find my daddy long leg (No 's')
Given the ratio of the two legs (longer / shorter), and the hypotenuse length, find the value of the bigger leg.

4 years 前

已解决


Solve a System of Linear Equations
*Example*: If a system of linear equations in _x&#8321_ and _x&#8322_ is: 2 _x₁_ + _x₂_ = 2 _x₁...

4 years 前

已解决


Max of a Vector
Write a function to return the max of a vector

4 years 前

已解决


Replace Vector Elements
Replace all elements in a vector which are equal to or smaller than zero with 0.1. Example: A = [1 2 3 -1 0 2 -3 -80]; ...

4 years 前

已解决


Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...

4 years 前

已解决


Problem for beginners
Suppose that x is a column vector, with at least a length of 6. Delete the 2., 6., and the second last row. Example: X=[1;2;3...

4 years 前

已解决


Mid-term report
You just got your mid-term report, but it's full of ones and twos :(. So before you give it to your parents, you change it, in o...

4 years 前

已解决


Simple Matrix
Make the following matrix without typing it in one by one. [1 2 3; 2 4 6; 4 8 12] x=[1 2 3].

4 years 前

已解决


Box
Give the volume of a box, x is equal to the body diagonal.

4 years 前

加载更多