Resuelto


Times 9
Try out this test problem first. Given the variable x as your input, multiply it by nine and put the result in y. Examples...

alrededor de 6 años hace

Resuelto


Times 12
Try out this test problem first. Given the variable x as your input, multiply it by twelve and put the result in y. Exampl...

alrededor de 6 años hace

Resuelto


Times 20
Try out this test problem first. Given the variable x as your input, multiply it by ninety and put the result in y. Exampl...

alrededor de 6 años hace

Resuelto


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

alrededor de 6 años hace

Resuelto


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]

alrededor de 6 años hace

Resuelto


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

alrededor de 6 años hace

Resuelto


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

alrededor de 6 años hace

Resuelto


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

alrededor de 6 años hace

Resuelto


Squares of odd numbers upto a given range
Find the squares of odd numbers upto a given range. If Given x=6 return y=(1^2,3^2,5^2) y=1,9,25 If Given x=5 retu...

alrededor de 6 años hace

Resuelto


Count the non-zero elements along the diagonals that are immediately next to the main diagonal
Suppose, you are being told to write a matrix, *a* as input in MATLAB with having the possibility of containing zero and non-zer...

alrededor de 6 años hace

Resuelto


Problem for beginners
M is a nxm matrix. Swap the fist and the second last column with eachother. X=[1 2 3;4 5 6;7 8 9] Y=[2 1 3;5 4 6;8 7 9]

alrededor de 6 años hace

Resuelto


cross-section of 3D pyramid
Create 3d pyramid of ones and zeros...where pyramid-part is denoted by ones and outer-part is denoted by zeros..where base is sq...

alrededor de 6 años hace

Resuelto


Is this matrix orthogonal?
Given a square matrix, a, determine whether it is orthogonal. INPUT: a, a n x n matrix OUTPUT: true or false

alrededor de 6 años hace

Resuelto


Projector Matrix
Write a function to determine whether or not the matrix is a projector. Projector matrices are defined as P^2 = P.

alrededor de 6 años hace

Resuelto


Back to basics 7 - Equal NaNs
Covering some basic topics I haven't seen elsewhere on Cody. Given 2 input variables, output true if they are equal, false ot...

alrededor de 6 años hace

Resuelto


Binary Coder
Take an input number and print the binary value of this number.

alrededor de 6 años hace

Resuelto


Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man? Give the name of that man, who, by popular believe, can ...

alrededor de 6 años hace

Resuelto


Area of a Square
Given the length x of the side of a regular square, find the area of the square, A.

alrededor de 6 años hace

Resuelto


Number of o rderd pairs of integers (I,J) that can be formed.
Write a MATLAB function that calculates the number of ordered pairs of integers (I, J) that can be formed satisfying the condit...

alrededor de 6 años hace

Resuelto


Four digit number ABCD reversal
write a MATLAB function to find the four-digit number ABCD when multiplied by 4 returns DCBA. The function takes an input x=4.

alrededor de 6 años hace

Resuelto


Reverse a string
Reverse the given string. Example input = 'reverse' output = 'esrever'

alrededor de 6 años hace

Resuelto


Perimeter of a square!
Calculate the circumference of the square whose side is n

alrededor de 6 años hace

Resuelto


How many points lie within the rectangle and how many aren't?
Suppose, you are given the coordinates of bottom-left and top-right corners of a rectangle as *input-1, R* i.e *R=[Bottom-left c...

alrededor de 6 años hace

Resuelto


Sum 1 to 100 even number
Write a Matlab program to add all the even numbers from 0 to 100 |

alrededor de 6 años hace

Resuelto


Function Iterator
Given a handle fh to a function which takes a scalar input and returns a scalar output and an integer n >= 1, return a handle f...

alrededor de 6 años hace

Resuelto


Find state names that end with the letter A
Given a list of US states, remove all the states that end with the letter A. Example: Input s1 = 'Alabama Montana Nebras...

alrededor de 6 años hace

Resuelto


reverse string
input='rama' output='amar'

alrededor de 6 años hace

Resuelto


"Low : High - Low : High - Turn around " -- Create a subindices vector
Let two vectors *lo* and *hi* be given. The job is to create a index vector like so idx = [lo(1):hi(1) lo(2):hi(2) ...]...

alrededor de 6 años hace

Resuelto


Generate a random matrix A of (1,-1)
Input n: is an positive integer which serves as the dimension of the matrix A; Output: A=(Aij),where each entry Aij is either...

alrededor de 6 años hace

Resuelto


BASICS - sum part of vector
Please make a function, where as input you get vector "x" and and vector "c", where in "c" vector you get indexes to sum. Examp...

alrededor de 6 años hace

Cargar más