Solved


modulus of a number
find the modulus of a given number

2 years ago

Solved


Find the largest value in the 3D matrix
Given a 3D matrix A, find the largest value. Example >> A = 1:9; >> A = reshape(A,[3 1 3]); >> islargest(A) a...

2 years ago

Solved


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

2 years ago

Solved


Divide by 4
Given the variable x as your input, divide it by 4 and put the result in y.

2 years ago

Solved


Factorial Numbers
Factorial is multiplication of integers. So factorial of 6 is 720 = 1 * 2 * 3 * 4* 5 *6 Thus 6 factorial = factorial(720)....

2 years ago

Solved


Find the sum of n squares
What is the sum of the squares of the first n integers?

2 years ago

Solved


factorial of a number x
Factorial of a number x

2 years ago

Solved


Return 'on' or 'off'
When the input is true, return 'on', otherwise, return 'off'.

2 years ago

Solved


Calculate the base-10 logarithm of a number
Calculate the logarithm of number x

2 years ago

Solved


calculate the tangent of angle in radians
Calculate the tangent of angle in degrees

2 years ago

Solved


Speed of car
Calculate the Speed of car given its Distance travelled and time taken in x and y respectively

2 years ago

Solved


pressure to dB?
given x ratio of pressure, find corresponding y dB

2 years ago

Solved


step function

2 years ago

Solved


Size

2 years ago

Solved


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

2 years ago

Solved


Square a Number
Given an input x, return y, which is equal to the square of x.

2 years ago

Solved


sign function

2 years ago

Solved


Matlab Basics - Convert a row vector to a column vector
Write a script to convert a row (e.g. x = [1 2 3]) to a column (e.g. y = [1;2;3]), your script should be able to do this for any...

2 years ago

Solved


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]

2 years ago

Solved


Sum of the Matrix Elements
Add up all the elements in a NxM matrix where N signifies the number of the rows and M signifies the number of the columns. E...

2 years ago

Solved


Matlab Basics - Create a row vector
Write a Matlab script to create a row vector of 10 consecutive numbers x = [1 2 3 4 5 6 7 8 9 10]

2 years ago

Solved


Summation of array
Given an array, Find the sum of all of the elements in it Examples: Input x = [1 2 3 5; 4 5 6 7]; Output y is 33

2 years ago

Solved


Back to basics 10 - Max Float
Covering some basic topics I haven't seen elsewhere on Cody. Return the largest positive floating-point number MATLAB can han...

2 years ago

Solved


Basic arrays operations.
Apply element-by-element binary operation 'fun' to two arrays (A and B).

2 years ago

Solved


Sum of the Multiplication of Vectors
Given the vectors x and y as input, multiply the vectors and return the summation of its elements. Example: x = [1 2 ...

2 years ago

Solved


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

2 years ago

Solved


surface of a spherical planet
you just discovered its circumference, that is the input.

2 years ago

Solved


Rotate counterclockwise a matrix 90 deg with left-bottom element
Example: Input [ 1 2 3 4 5 6 ] Output [ 3 6 2 5 1 4 ]

2 years ago

Solved


Tell me the slope
Tell me the slope, given a vector with horizontal run first and vertical rise next. Example input: x = [10 2];

2 years ago

Solved


Program an exclusive OR operation with logical operators
Program an exclusive or operation *without* using the MATLAB function xor. Use logical operators like |, &, ~, ... instead. ...

2 years ago

Load more