A résolu


find the surface area of a cube
given cube side length x, find the surface area of the cube, set it equal to y

environ 2 ans il y a

A résolu


metre to feet converter
The idea is to make a converter, which exchange meters to feets. We use a factor of 1m = 3.281*1f. so 3m are equals to 9.843 m...

environ 2 ans il y a

A résolu


Unit Matrix
Given n, you should return an n-by-n unit matrix. Example: If input is n=2 then A = [ 1 0 0 1 ] If input is n=4 th...

environ 2 ans il y a

A résolu


Basics: 'Find the eigenvalues of given matrix
Find the eigenvalues y for a given matrix x.

environ 2 ans il y a

A résolu


Volume of a box
Given a box with a length a, width b, and height c. Solve the volume of the box.

environ 2 ans il y a

A résolu


Multiply a column by a row
* Given a column vector C and and a row vector R. * Output a matrix M. * Every column of M equals to C multiplied by correspon...

environ 2 ans il y a

A résolu


Arrange vector in ascending order
Arrange a given vector in ascending order. input = [4 5 1 2 9]; output = [1 2 4 5 9];

environ 2 ans il y a

A résolu


Celsius to Kelvin
Convert Celsius degrees to Kelvin temperature.

environ 2 ans il y a

A résolu


Find the product of a Vector
How would you find the product of the vector [1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0] times 2?; x = [1 : 0.5 : 6]; y ...

environ 2 ans il y a

A résolu


Matlab Basics II - Intervals
Write a function that takes an interval from a to b, and divides it into 5 parts example: a = 1, b = 2 output = 1 1.25 ...

environ 2 ans il y a

A résolu


Find parts of a circle.
Given radius (r) of a circle find the diameter (d), circumference (c), an area (a).

environ 2 ans il y a

A résolu


Negative matrix
Change the sign of all elements in given matrix.

environ 2 ans il y a

A résolu


Sum of first n positive integers
Given n, find the sum of first n positive integers Example: If n=10, then x=1,2,3,4,5,6,7,8,9,10. The sum of these terms is 55

environ 2 ans il y a

A résolu


Matlab Basics - Absolute Value
Write a script that returns the absolute value of the elements in x e.g. x = [-1 -2 -3 -4] --> y = [1 2 3 4]

environ 2 ans il y a

A résolu


Summing Rows and Columns
Create a matrix y of size (n+1) whose last column's elements are the summation of the elements of all the other columns and last...

environ 2 ans il y a

A résolu


Find alternating sum
Given an array, find alternating sum i.e. – y = x (1) – x (2) + x (3) – x (4) + x (5) - …

environ 2 ans il y a

A résolu


Extract the prime numbers
Given a list of elements, extract the prime numbers from that array.

environ 2 ans il y a

A résolu


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

environ 2 ans il y a

A résolu


Vectorize the digits of an Integer
Create a vector of length N for an integer of N digits. x = 123045; x_vec = [1 2 3 0 4 5]; I happened upon a trick ...

environ 2 ans il y a

A résolu


Do you like your boss?
Do you like your boss? Answer can be any string! For example: Boss = 'Do you like your boss?'; Output = 'yes' or ...

environ 2 ans il y a

A résolu


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

environ 2 ans il y a

A résolu


Prime numbers between a , b.
Find all prime number between a & b (including a and b). example: a=100 b=120 y= [101 103 107 109 113]

environ 2 ans il y a

A résolu


Who has power to do everything in this world?
There is only one person who is older than this universe. He is Indian version of Chuck Norris.

environ 2 ans il y a

A résolu


Find all repeated numbers
For a given vector, find all numbers that repeated 2 times or more than 2 times. Example: A=[1 2 3 3 4 5 6 6 7] y=[3 ...

environ 2 ans il y a

A résolu


convert the number to binary format & count digits
Convert the given number to the corresponding binary format and count the number of digits in that binary number

environ 2 ans il y a

A résolu


Basics: counting digits of a number irrespective of the sign
publish the number of digits in any input integer example: -23---->2

environ 2 ans il y a

A résolu


Check if there are white spaces in the input string
If there are white spaces in the input string, output=1 else 0

environ 2 ans il y a

A résolu


Basic Quadratic Equation
Create the equation: y=(3x)^2+(5x)+35 and compute y for various values of x

environ 2 ans il y a

A résolu


find number of times of occurrence of the most frequent number in a row vector
In a given row vector, find the number of times a mode of a row vector has occurred example: in [2 5 5 5 5 3], output is 4 ...

environ 2 ans il y a

A résolu


Second Diagonal
Transpose the matrix from it's second diagonal.

environ 2 ans il y a

Charger plus