A résolu


Crop an Image
A grayscale image is represented as a matrix in MATLAB. Each matrix element represents a pixel in the image. An element value re...

presque 4 ans il y a

A résolu


Find the Best Hotels
Given three input variables: * |hotels| - a list of hotel names * |ratings| - their ratings in a city * |cutoff| - the rat...

presque 4 ans il y a

A résolu


Calculate BMI
Given a matrix |hw| (height and weight) with two columns, calculate BMI using these formulas: * 1 kilogram = 2.2 pounds * 1 ...

presque 4 ans il y a

A résolu


Calculate a Damped Sinusoid
The equation of a damped sinusoid can be written as |y = A.ⅇ^(-λt)*cos(2πft)| where |A|, |λ|, and |f| ...

presque 4 ans il y a

A résolu


Calculate Inner Product
Given two input matrices, |x| and |y|, check if their inner dimensions match. * If they match, create an output variable |z|...

presque 4 ans il y a

A résolu


Verify Law of Large Numbers
If a large number of fair N-sided dice are rolled, the average of the simulated rolls is likely to be close to the mean of 1,2,....

presque 4 ans il y a

A résolu


Solve a System of Linear Equations
*Example*: If a system of linear equations in _x&#8321_ and _x&#8322_ is: 2 _x₁_ + _x₂_ = 2 _x₁...

presque 4 ans il y a

A résolu


Get all prime factors
List the prime factors for the input number, in decreasing order. List each factor. If the prime factor occurs twice, list it as...

presque 4 ans il y a

A résolu


Smith numbers
Return true if the input is a Smith number in base ten. Otherwise, return false. Read about Smith numbers at <http://en.wikipedi...

presque 4 ans il y a

A résolu


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

presque 4 ans il y a

A résolu


Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle. <<https://i.imgu...

presque 4 ans il y a

A résolu


Maximum value in a matrix
Find the maximum value in the given matrix. For example, if A = [1 2 3; 4 7 8; 0 9 1]; then the answer is 9.

presque 4 ans il y a

A résolu


Find the Oldest Person in a Room
Given two input vectors: * |name| - user last names * |age| - corresponding age of the person Return the name of the ol...

presque 4 ans il y a

A résolu


Convert from Fahrenheit to Celsius
Given an input vector |F| containing temperature values in Fahrenheit, return an output vector |C| that contains the values in C...

presque 4 ans il y a

A résolu


Calculate Amount of Cake Frosting
Given two input variables |r| and |h|, which stand for the radius and height of a cake, calculate the surface area of the cake y...

presque 4 ans il y a

A résolu


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

presque 4 ans il y a

A résolu


When the sum of the cubes is a quartic...

presque 4 ans il y a

A résolu


Bleed non-zeros to the right
What a title! Yet, it says what I mean. You get a vector, some values and a lot of zeroes. Every zero is replaced by the firs...

presque 11 ans il y a

A résolu


Swap two numbers
Example Input: a = 10 b = 20 Output a = 20 b = 10

presque 11 ans il y a

A résolu


What percentage?
Calculate the output c as the percentage of a on b for given a and b.

plus de 11 ans il y a

A résolu


CARDS PROBLEM
Read my mind and tell me the card number that I have now in my hands.

plus de 11 ans il y a

A résolu


Relative ratio of "1" in binary number
Input(n) is positive integer number Output(r) is (number of "1" in binary input) / (number of bits). Example: * n=0; r=...

plus de 11 ans il y a

A résolu


factor to number
e.g. input number x=10 then it should produce y=25 or x=100 then y should be 2255. write a function or code to generate the same...

plus de 11 ans il y a

A résolu


Make a vector of prime numbers
Input(n) - length of vector with prime numbers Output(v) - vector of prime numbers Example: * n=1; v=2 * n=3; v=[2 3 5...

plus de 11 ans il y a

A résolu


Is the input divisible by 3?
Return true if the input is divisible by 3 and false if not.

plus de 11 ans il y a

A résolu


The sum of the numbers in the vector
eg. [1,2,3]---->SUM=6

plus de 11 ans il y a

A résolu


Volume and area of a sphere
Input(r) - radius Output([v,s]) - volume and area

plus de 11 ans il y a

A résolu


How many digits are there?
Input(s) - any string Output(n) - number of digits within string s

plus de 11 ans il y a

A résolu


Calculate the integral of the polynomial
for e.g. in = [3 2 1] out = [1 1 1 0]

plus de 11 ans il y a

A résolu


calculate linear convolution two vectors
for e.g in: a = [1 2 3] b = [4 5 6] out: y = [4 13 28 27 18]

plus de 11 ans il y a

Charger plus