Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


BaeIsAlwaysRight
Output yes whatever bae says

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


"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).

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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)* ...

quasi 7 anni fa

Risolto


Nth root
Nth root of a number x

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


Create sine function out of cosine
Please don't use sin(x) directly

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Risolto


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

quasi 7 anni fa

Carica altro