Solved


Minimal Path - 03
Given a matrix, find the minimal path sum from the top left to the bottom right corner. Now you can move up, right & down. ...

2 months ago

Solved


Minimal Path - 02
Given a matrix, find the minimal path from the top left to the bottom right by only moving to the right and down so that the sum...

2 months ago

Solved


Spiral Out - 02
An array is given. Convert it into a spiral matrix. For example, a=1:27; out=[21 22 23 24 25 26 20 ...

2 months ago

Solved


Spiral Out - 01
Create a spiral matrix ( clock-wise direction ) of size n. Try to do that without using the built-in function.

2 months ago

Solved


Don't be Too Greedy!!
Refer to the prev problem <https://www.mathworks.com/matlabcentral/cody/problems/45450-don-t-be-too-greedy> For this time, ca...

2 months ago

Solved


Don't be Too Greedy!
Refer to the prev problem <https://www.mathworks.com/matlabcentral/cody/problems/45416-don-t-be-greedy> A list of assignments...

2 months ago

Solved


Vector raised to a power, element-wise (★)
Given a vector A and a number x, raise each element of the vector to the power of x. Thus, if A = [2 5 7 1] and x = 0.5, then ...

2 months ago

Solved


Element-wise vector product (★)
Given two vectors x and y, compute their element-wise product z. Thus, if x = [1 3 5] and y = [0.5 -1 2], then z = [1*0.5...

2 months ago

Solved


Create logarithmically spaced values (★)
Given three numbers a,b,n with b>a, create a vector y with n logarithmic spaced values between 10^a and 10^b. Thus, if a = -2, ...

2 months ago

Solved


Create a vector of the first n natural numbers (★)
If n = 7, your program should return a vector y, where y = [1 2 3 4 5 6 7].

2 months ago

Solved


Create a vector with n repeated values of a number x (★★)
If x=3 and n=7 then the vector y would be y=[3 3 3 3 3 3 3]

2 months ago

Solved


Generate n equally spaced "intervals" between -x and x (★)
Given n and x, return a list of numbers (in ascending order) that divides the interval [-x x] into n equal-length intervals. ...

2 months ago

Solved


PEMDAS test (★★)
Create the function that will return the following expression for x and y. <<https://i.ibb.co/RHWyzrv/Code-Cogs-Eqn-1.gif>> ...

2 months ago

Solved


Create a vector of n alternating ones and zeros (★★)
Given n, your output should be a vector y of numbers such that the first number is 1 and the numbers following it alternate betw...

2 months ago

Solved


Create a vector of the first n odd numbers (★)
If n = 10, your program should return a vector y, where y = [1 3 5 7 9 11 13 15 17 19].

2 months ago

Solved


Successive zeros (harder)
The problem is from Problem 45436, <https://www.mathworks.com/matlabcentral/cody/problems/45436-successive-zeros> Suppose n i...

2 months ago

Solved


Successive zeros
Suppose n is the number of digits a number contains. Now, 12032 - is a valid n=5 digit number. But 10023 - is defined as i...

2 months ago

Solved


Capitalize
Capitalize the 1st letter of each input. Other letters should be lowercase. For example - a='alphaS' >> 'Alphas' a='1...

2 months ago

Solved


Pipeline - Variable-length Input
Design the |gt|(>) method of |function_handle| so that: >> 1 > @sin > @cos ans = 0.666366745392881 >> cos(sin(1...

2 months ago

Solved


Weighted Names
A cell is given which contains several names. You've to return those names sorted by their weight. Weight is to be calculate...

2 months ago

Solved


Juego de posiciones
Crea una función que ordene vectores de tal manera que los primeros números sean negativos ordenados de menor a mayor. Y después...

2 months ago

Solved


Prime Sum
What is the minimum value that can be written as sum of primes in n different ways? For example, 10 is the minimum value th...

2 months ago

Solved


Minimal Path - 01
Given a matrix, find the minimal path sum from the top left to the bottom right by only moving to the right and down. For exa...

2 months ago

Solved


Amicable pair
Amicable numbers are two different numbers such that the sum of the proper divisors of each is equal to the other number. For e...

2 months ago

Solved


Determina el número de cifras de un número
Crea una función que te devuelva el número de cifras de un número. Algunos ejemplos para ayudarte serían: El número 125 tie...

2 months ago

Solved


Bernoulli's Triangle
Generate the bernoulli's triangle upto nth row. <https://mathworld.wolfram.com/BernoulliTriangle.html>

2 months ago

Solved


Abelian Sandpile - 02
Generate a matrix like Abelian Sandpile where the four corner element is n. For example, n=4 [4 3 2 1 ...

2 months ago

Solved


Abelian Sandpile - 01
Generate a matrix like abelian sandpile where the center of the matrix is n. For example, n=3 out=[0 0 0 0 ...

2 months ago

Solved


Fault in our Stars - 02
Create a window pattern with h-horizontal bars and v-vertical bars. For example, for h=4,v=4 '**********' '* ...

2 months ago

Solved


Don't be Greedy!
A list of assignments is given to the students along with the submission deadlines. Each of the assignment contains particular...

2 months ago

Load more