Solved


Generate this matrix
For a given odd integer n, generate a matrix as follows: Input: n = 5; Output: [ 2 1 0 0 0 1 ...

7 years ago

Solved


The Matrix Construction
Given two input ,first one is CN (Column Number), Second one is Dim Can you produce such a matrix for example CN=6; Dim=2 ...

7 years ago

Solved


Create a block diagonal matrix
A block diagonal matrix is a square matrix that can be written as A = [a 0 0 0 0 b 0 0 0 0 c 0 ...

7 years ago

Solved


Matrix Construction I
Given n, construct a matrix as shown in the example below. Example For n=8, the output should look like this: 1 2 3 4 ...

7 years ago

Solved


Gauss Eliminate 2-by-2 example
Use forward elimination to make the coefficient matrix, A, an upper triangular matrix, and then solve using back substitution, f...

7 years ago

Solved


how to concatenate matrices
What is the name of the function used to create a matrix C form two matrices A and B, using the syntax: C = [A B]; Outpu...

7 years ago

Solved


balance vector
Given a non-empty vector x with integer elements. x shall be called balance vector if one can split the elements of x into two g...

7 years ago

Solved


0, 2, 0, -2, 0, 2, 0, -2, ...
Generate the first n terms of a periodic sequence defined as f(x) = 0, 2, 0, -2, 0, 2, 0, -2, ..., for x = 1, 2, 3, 4, 5, 6...

7 years ago

Solved


Find out sum of prime number till given number
Find out sum of prime number till given number Example, if number is 10, then answer must be 17.

7 years ago

Solved


Volume of this donut
Given hole diameter a, and outermost diameter b, determine the volume y of the resulting donut.

7 years ago

Solved


How many monitors are connected ?
How to obtain the numbers of monitors connected to your computer ?

7 years ago

Solved


High school cafeteria
Given an input vector of positive integers, return a row vector with the primes first (in increasing order) and the composites n...

7 years ago

Solved


Calculate distance travelled when given radius and rotations
When given radius of wheel and number of rotations calculate total distance travelled consider pi=3.14

7 years ago

Solved


prime test 2
enter the only non prime,non composite number

7 years ago

Solved


true or false
if the matrix has a zero, return true. else, return false

7 years ago

Solved


Radians to Degrees
Convert radians to degrees.

7 years ago

Solved


Initialize a Natural Number matrix.
Given length of matrix initialize a matrix consisting of natural numbers from 1 to n: n = 10; x = [ 1 2 3 4 5 6 7 8 9 10]; ...

7 years ago

Solved


Find remainder when x is divided by 3
Find remainder when x is divided by 3

7 years ago

Solved


row removal
Remove the nth row from input matrix M and return the resulting matrix in output N.

7 years ago

Solved


modulus of a number
find the modulus of a given number

7 years ago

Solved


Flipping a Matrix
Flipping matrix up and down. If a central row is exists, leave it, and flip remaining rows. Example Mat = magic(3) ...

7 years ago

Solved


determine the sum of the squares
if x = 4, the solution will be: y = 1^2+2^2+3^2+4^2=1+4+9+16 = 30.

7 years ago

Solved


Degrees to Radian
Convert degrees to radians

7 years ago

Solved


Kinetic Energy
Given the mass m and velocity v of an object, determine its <http://en.wikipedia.org/wiki/Kinetic_energy kinetic energy>.

7 years ago

Solved


Sum positive elements of matrix.
Calculate sum of positive elements of the matrix.

7 years ago

Solved


Find hen's weight.
If hen weights x kilos on two legs, how much does it weights on one leg? Output the result.

7 years ago

Solved


MPS to MPH
Given the speed in miles per second, find the speed in miles per hour.

7 years ago

Solved


Back to basics - mean of corner elements of a matrix
Calculate the mean of corner elements of a matrix. e.g. a=[1 2 3; 4 5 6; 7 8 9;] Mean = (1+3+7+9)/4 = 5

7 years ago

Solved


ASCII Birthday Cake
Given an age and a name, give draw an ASCII birthday cake. For example, given the name "CODY" and the age 5, return a string wit...

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

7 years ago

Load more