Area of square
Find the area of a square whose diagonal length is given as x.
4 years ago
Solved
"Power matrix" of two vectors
Given two row vectors x,y of lengths m and n (respectively), create an m x n matrix whose i,j entry is x(i)^y(j).
4 years ago
Solved
Sum of terms in a series 1 (★★★)
Given x and n, compute the following sum:
|x|+|x|^(1/2)+|x|^(1/3)+|x|^(1/4)+|x|^(1/5) ... + |x|^(1/n)
where ||x|| indica...
4 years ago
Solved
Zero
given an integer a, find the smallest possible integer b(b>0) such that their bitwise logical AND is zero.
* if a=11(1011) t...
4 years ago
Solved
Swap the first and last columns (★★)
(copy of Prob 19)
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becom...
Even or Odd
Write a function which can tell us if the given value x is odd or even. So if x is even return true and if x is odd return false...
4 years ago
Solved
Finding sum of even numbers in a vector.
Find the sum of all the even numbers present in the input vector x.
Examples:
Input x = [1 2 3 4]
Output y is 6
Input...
4 years ago
Solved
row removal
Remove the nth row from input matrix M and return the resulting matrix in output N.
Determina si el número es primo
Primero, antes que nada: ¿Qué es un número primo?
Un número primo es cualquier número que solamente se puede dividir por 1 y ...