Solved


Given a vector x, return vector y with all negative elements from the vector x.
Given a vector x, return vector y with all negative elements from the vector x if x has negative elements. Otherwise return 0. ...

6 years ago

Solved


Square
square root of x

6 years ago

Solved


factorial
calculate x!

6 years ago

Solved


Sum Sum Sum!
Calculate the sum of the natural numbers from 1 to n

6 years ago

Solved


SAY 'OHYEAH'
Regardless of input, output the string 'OHYEAH'.

6 years ago

Solved


Perfect square.
Determine if the input is a perfect square or not. Example - If input is 25, return 1. If input is 17, return 0.

6 years ago

Solved


Power Numbers
Find the n-th power of m.

6 years ago

Solved


Convert a vector of Integers into a matrix of binaries
Convert a vector of positive integers into a matrix containing their binary representation. Each column of the output contains t...

6 years ago

Solved


Calculate the volume of the cube.
Example n = 3; a = volume(n); a = 27

6 years ago

Solved


Remove the middle element from a vector
Remove the middle element of a vector? *Example:* [1,2,3] should return 2 [1,2,3,4] should return 2 [] should return...

6 years ago

Solved


Largest territory
Determine whose territory is largest. If there are multiple numbers tied for the largest territory, return the smallest number. ...

6 years ago

Solved


Max Change in Consecutive Elements
If an array is given as input then find the index of consecutive elements that represent maximum change. Example: Input ...

6 years ago

Solved


random picture with random colours
write a function which creates a random(x,y) matrix with random RGB colours for example create_pic(5,5) gives us a 3d matrix. ...

6 years ago

Solved


Pairwise column flip
Given matrix *M_in*, flip every pair of columns. So if *M_in* is 1 2 3 4 1 2 3 4 then *M_out* is 2 1 4 3 2 1 4 3 ...

6 years ago

Solved


Create an m x n array consisting only of an input value.
Create an array with m rows and n columns wherein all entries are assigned the input value x.

6 years ago

Solved


How long does it take to run a bath?
Given the *volume flow rate* (volume/time) of a faucet and the *volume* of a bath tub, find the amount of time it takes to fill ...

6 years ago

Solved


row removal
Consider a matrix and remove the first row of the matrix.

6 years ago

Solved


create a circulant matrix
create a circulant matrix

6 years ago

Solved


Small Riddle
Mr. Smith has two children. If the older child is a boy, what are the odds that the other child is also a boy?

6 years ago

Solved


My Problem, Find the square of the horizontal concatenation of the third and fifth elements of a vector.
given the 1x5 vector x, y must be the square of the horizontal concatenation of the third and fifth elements. So, if x = [1 1 1 ...

6 years ago

Solved


Find the index of the first occurrence of a value in a matrix
Given a matrix of scalars, find the first occurrence of -1 in each column. Output NaN for a column which does not contain the va...

6 years ago

Solved


Hydrogens in a Saturated Hydrocarbon
Given (c) carbon atoms in a saturated hydrocarbon molecule (all single bonds), how many hydrogen atoms (h) are in the molecule?

6 years ago

Solved


Phonebook-like problem
strcmpi('Yes', 'No')

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

6 years ago

Solved


Alkane
Given a number, x, that is equal to the number of carbon atoms in an <http://en.wikipedia.org/wiki/Alkane alkane>, find, y, the ...

6 years ago

Solved


Reverse the input
Given an input (n), produce an output in the reverse order with out using string variables or string function. Example x ...

6 years ago

Solved


Give prime Numbers upto n
You are given a input number x; print all the prime numbers less than equal to x.

6 years ago

Solved


What's the missing interior angle?
I'm talking about polygons... The sum of the interior angles of a triangle is 180 degrees. The sum of the interior angles of a...

6 years ago

Solved


Vertically stack two vectors
Stack two vectors on top of each-other so that... if A = [1 5 3] and B = [8 6 4] then C = [1 5 3 ; 8 6 4]

6 years ago

Solved


Testing Problem Creation
This is where MATLAB based question will be

6 years ago

Load more