Gelöst


Queen's move
given a number of consecutive moves of queen, check for their validity based on their previous position.... but remember if u g...

3 Monate vor

Gelöst


Create a 3D rotation matrix from roll-pitch-yaw angles
Consider a robotics application where the world reference coordinate frame {W} and a robot manipulator arm with an attached tool...

3 Monate vor

Gelöst


Moving Median Absolute Deviation
The median absolute deviation (MAD) is defined as MAD = median(abs(A − median(A))) for a rolling window of length n. For examp...

3 Monate vor

Gelöst


Recurrence relation
A recurrence relation is given by P(1) := 1 P(n+1) := exp(1) - (n+1)*P(n) Write a function that, given an integer |...

3 Monate vor

Gelöst


Upstairs!
The stair has n steps. Every times you can up one or two steps. Give all the different solutions to upstairs. For example n ...

3 Monate vor

Gelöst


Higher! Lower!
My kids have started to play the "I'm thinking of a number between X and Y" game in the car on trips to and from their swim less...

3 Monate vor

Gelöst


Determine roll pitch yaw angles from a 3D rotation matrix
Consider an aerospace application where the world reference coordinate frame {W} and a body-fixed coordinate frame {B}. The ori...

3 Monate vor

Discussion


Using the Extended Euclidean Algorithm & Bézout’s Theorem
Many MATLAB Cody problems involve solving congruences, modular inverses, Diophantine equations, or simplifying ratios under cons...

3 Monate vor | 0

Gelöst


Now 20% off!
Furloughs are hitting government workers this year. To commemorate getting one unpaid day off each week until the end of Septem...

3 Monate vor

Gelöst


Coin Tossing: Probability of Same Heads for N tosses
A pair of physicists toss a coin n times each. What is the probability that they tossed the same number of heads? Input: N % n...

3 Monate vor

Gelöst


Tell your secret
A secret can be told only to 2 persons in 5 minutes. Now, these 2 more persons can spread the secret to 4 other people in the ne...

3 Monate vor

Gelöst


Vigenere cipher - be like Sherlock Holmes!
You're a young detective. Every detective needs a function to decrypt a vigenère cipher. It's a modification of a caesar cipher....

3 Monate vor

Gelöst


Exponents in Factorials(hard)
This is problem is a harder version of "Problem 44747. Exponents in Factorials". <https://ww2.mathworks.cn/matlabcentral/cody/p...

3 Monate vor

Gelöst


Collect a set of candy wrappers
This past Halloween, the siblings Matilda and Labrun amused (and sometimes confused) their many neighbors with their costumes in...

3 Monate vor

Gelöst


Can you beat the lottery?
Well this one you may not get every time, but it is a lottery! Here is the code that generates the lottery numbers (you can try ...

3 Monate vor

Gelöst


Who am I ?
Who am I ? Write any function that reveals itself under these constraints. Hint: I am combinatorial code, and I don't like stat...

3 Monate vor

Gelöst


Sum the Infinite Series II
For any x in the range 0 < x and x < 2*pi radians, find the sum of the following infinite series: c = 1 + 1/2*cos(x) + 1/2*3/4...

3 Monate vor

Gelöst


Persistence will not help you solve this problem.
Create a function without inputs that adds one to the output every time it is called. A different possibility of solving this ha...

3 Monate vor

Gelöst


Get Cody's screen size
Return an object that helps this problem's test suite return Cody's screen size.

3 Monate vor

Gelöst


Sieve of Eratosthenes
Find the nth lucky prime number. <https://planetmath.org/luckyprime> can u find a way for large n?

3 Monate vor

Gelöst


Filter British English into American English
Given a sentence written with British spelling, return the sentence with the offending word(s) replaced with the American spelli...

3 Monate vor

Gelöst


Orthogonal lines
Check whether two given lines are orthogonal or not. Two lines are orthogonal if they create a right angle at their intersect...

3 Monate vor

Gelöst


Height of a four-pointed star polygon
Given the area A, of a rectangle with dimensions l1xl2, where the side lengths are integers and form the smallest possible perim...

3 Monate vor

Gelöst


Covering rectangle area of a four-pointed star polygon
Given the four-pointed star polygon formed by the rectangle, with dimensions l1xl2, and four triangles, with height, h, from the...

3 Monate vor

Gelöst


sparse_matrix
You convert a vector to a sparse matrix. for example *x* =[1 2 3]; output will be *y* = [1 0 0 ...

3 Monate vor

Gelöst


Selecting books on MATLAB for experts and beginners (blindfolded)
* Imagine you have been blindfolded and asked to pick up any two books randomly from the table. * There are n books suitable f...

3 Monate vor

Gelöst


Calculate SNR in dB using original signal and quantized signal
origs: the original signal quants: the quantized signal *hint* : need to calculate the quantization error and plug into SN...

3 Monate vor

Gelöst


Count the Even Digits in a Number
Given a positive integer n, write a function that returns how many digits of n are even. Even digits are: 0, 2, 4, 6, 8

3 Monate vor

Gelöst


Find the path through the cell
A list of cells is given. Return true if the elements of the list increase monotonically (each element is strictly larger tha...

3 Monate vor

Gelöst


Rainbow matrix
Create a "rainbow matrix" as described in the following examples Input = 3 Output = [ 1 2 3 2 3 2 ...

3 Monate vor

Mehr laden