Solved


Negative Infinity
Round the given array a towards negative infinity.

2 years ago

Solved


Area of a disk
Find the area of a disk or circle. x= radius of the disk.

2 years ago

Solved


Reverse a matrix
Its simple. You have to reverse a given matrix.

2 years ago

Solved


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

2 years ago

Solved


Vectors counting by 2
Create a vector numbers from 7 to 15 in increments of 2

2 years ago

Solved


No Twins?
Write a function that accepts as input a vector and returns the same vector, but retaining only the first occurrence of an eleme...

2 years ago

Solved


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

2 years ago

Solved


Least common multiple of many numbers
1:6 -> 60

2 years ago

Solved


04 - Scalar Equations 2
Define the variables a and b: <<http://samle.dk/STTBDP/Assignment1_4-a.png>> <<http://samle.dk/STTBDP/Assignment1_4-b.png>...

2 years ago

Solved


Solving Quadratic Equations (Version 1)
Quadratic equations have the form: ax^2 + bx + c = 0. Example: x^2 + 3x + 2 = 0, where a = 1, b = 3, and c = 2. The equation has...

2 years ago

Solved


Area of a circle
Given the radius x, y would be the area of a circle. Pi = 3.1416

2 years ago

Solved


Transpose
Write a MATLAB script in order to convert a random length row vector (v) into a column vector.

2 years ago

Solved


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

2 years ago

Solved


Multiply 2 numbers
Very easy, you just have to multiply 2 numbers but you cannot use the following signs (*, /, - ,^) ,mtimes , times, cross, pro...

2 years ago

Solved


Find the area of the four walls
If length, breadth and height of the walls are given, find the area of the four walls.

2 years ago

Solved


ASCii Code
Using Matlab get the ASCii for '?'

2 years ago

Solved


Find the hypotenuse
Given a and b (the two sides of a right-triangle), find c, the hypotenuse.

2 years ago

Solved


Back to basics 25 - Valid variable names
Covering some basic topics I haven't seen elsewhere on Cody. Given a string, return true if it is a valid MATLAB variable nam...

2 years ago

Solved


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

2 years ago

Solved


Find the nearest integer
Given a vector of integers and a real number find the closest integer. EX: >> a = [2 4 5 6 8 10]; >> b = 4.6; >> nea...

2 years ago

Solved


Remove white space from the string
Remove the white spaces (trailing and leading) from the input variable

2 years ago

Solved


Back to basics 14 - Keywords
Covering some basic topics I haven't seen elsewhere on Cody. Return a cell array of all MATLAB keywords

2 years ago

Solved


Getting the absolute index from a matrix
This is a basic MATLAB operation. It is for instructional purposes. --- You may already know how to get the <http://www.ma...

2 years ago

Solved


Clamper Function
Create a function that emulates a clamper circuit Given sin wave, t and the constant value for clamping

2 years ago

Solved


N-th permutation.
Let write some permutations of positive integers. 1: 1 2 3 4 5 6 ... 2: 2 1 3 4 ... 3: 1 3 2 4 ... ...

2 years ago

Solved


Which permutation is it?
Let write some permutations of positive integers. 1: 1 2 3 4 5 6 ... 2: 2 1 3 4 ... 3: 1 3 2 4 ....

2 years ago

Solved


What can you get for exactly amount of money(harder)
Inspired by "Problem 42996. what can you get for exactly amount of money" <https://ww2.mathworks.cn/matlabcentral/cody/problems...

2 years ago

Solved


Recycled Numbers (CodeJam Qualification Round 2012)
Let's say a pair of distinct positive integers ( _n_ , _m_ ) is recycled if you can obtain _m_ by moving some digits from the ...

2 years ago

Solved


Calculate the height of an object dropped from the sky
Assume that an object is dropped from 1000 meters above the surface of the earth at time t=0. The object is dropped such that t...

2 years ago

Solved


How Far Can You Throw Something?
As you probably learned in your high school physics class, throwing an object at a 45 degree angle will give you the maximum ran...

2 years ago

Load more