Solved

Calculate the number of elements in a matrix.
Calculate the number of elements in a matrix.

oltre 4 anni ago

Solved

Magnitude of a vector
Given a vector x, what is its magnitude?

oltre 4 anni ago

Solved

Odd times 3
Given a input matrix x, multiply all odd values by 3. Even values remain the same. example: x = [1 2 3 4 5;... 6 7...

oltre 4 anni ago

Solved

A shooting competition
In a shooting competition, the target is a square of side L containing a circle of radius R<=L/2. A player scores one point if h...

oltre 4 anni ago

Solved

Circular Shift Me
Given a vector v=[1 3 6 9 11], circular shift them while iterating m=[1 3 6 9 11; 11 1 3 6 9; 9 11 1 3 6; 6 9 11 1 3; 3 6 9 1...

oltre 4 anni ago

Solved

How do you make seven even?
Take away the s.

oltre 4 anni ago

Solved

Create cell array of strings
Convert the input to a cell array, but only if necessary. If the input is a string, return a 1-by-1 cell array containing the...

oltre 4 anni ago

Solved

I told you not separate me, but you did :( - ACDC
Given input vector, output it's DC and AC value Example: input = 0 1 -1 0 ac = 0 1 -1 0 dc = 0

oltre 4 anni ago

Solved

Performance - summation
Given a vector of natural numbers x = [1,2,3,...,N] compute the sum of its elements by not stressing the machine too much...

oltre 4 anni ago

Solved

All odd - all even
All odd numbers in x are added, while all even numers are subtracted from this. example: x = [1 2 3 4 5]; y = +(1+3+5)-...

oltre 4 anni 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) ...

oltre 4 anni ago

Solved

Permutations of input vector
Find and output all permutations of given vector

oltre 4 anni ago

Solved

Can I make a right triangle ?
Input(a) - is vector with any amount of values. Interpreted as legths of sides. Output(b): * Is true if there are any 3 va...

oltre 4 anni ago

Solved

Linear system of equations
Solve the system of equations in three variables.

oltre 4 anni ago

Solved

Print true if
all elements are larger than 5 a=[1 3 5 8 6]; b=[6 6 6 6 6]; function(a) should be false, and function(b) will be tru...

oltre 4 anni ago

Solved

Convert Kilometers to Miles
Convert kilometers to miles. Consider 1 km = 0.62 mile. Note: Don't use the '*' operator.

oltre 4 anni ago

Solved

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

oltre 4 anni ago

Solved

Pointwise multiplication of vectors.
Pointwise multiplication of vectors x and y. Example x= [1 3 5 7 9 11 13 15 17 19] y=[ 1 4...

oltre 4 anni ago

Solved

BaeIsAlwaysRight
Output yes whatever bae says

oltre 4 anni ago

Solved

Annoying population
Every year the number of annoying persons in the office triples Found the population, given a(0) and t

oltre 4 anni ago

Solved

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

oltre 4 anni 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).

oltre 4 anni ago

Solved

Find the definite integral of various linear functions
A definite integral had a minimum and maximum limit. When you solve this type of problem you must use both quad and the trapz fu...

oltre 4 anni ago

Solved

Calculate the centroid of a triangle
Info: https://en.wikipedia.org/wiki/Centroid Example Input: x = [0 0 1]; % x-coordinate y = [0 1 0]; % y-coordinat...

oltre 4 anni ago

Solved

Combinations without using nchoosek
You have to generate a matrix with all possible combinations of n elements *taken 2* at a time, *without using nchoosek(1:n,2)* ...

oltre 4 anni ago

Solved

Nth root
Nth root of a number x

oltre 4 anni ago

Solved

Polynomial Evaluation
Create a routine that takes a list of coefficients of a polynomial in order of increasing powers of x; together with a value of ...

oltre 4 anni ago

Solved

Create sine function out of cosine

oltre 4 anni ago

Solved

Find the alphabetic word product
If the input string s is a word like 'hello', then the output word product p is a number based on the correspondence a=1, b=2, ....

oltre 4 anni ago

Solved

Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

oltre 4 anni ago