Resuelto


Tricky timing
Write a function that takes between 0.5 seconds and 0.6 seconds to run.

casi 12 años hace

Resuelto


Alternating sum
Given vector x, calculate the alternating sum y = x(1) - x(2) + x(3) - x(4) + ...

casi 12 años hace

Resuelto


Add two numbers
Add two numbers (For beginners)

casi 12 años hace

Resuelto


02 - Vector Variables 2
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_2b.png>>

casi 12 años hace

Resuelto


The sum of the numbers in the vector
eg. [1,2,3]---->SUM=6

casi 12 años hace

Resuelto


Fahrenheit to Celsius converter
Convert Fahrenheit to Celsius degrees.

casi 12 años hace

Resuelto


Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...

casi 12 años hace

Resuelto


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

casi 12 años hace

Resuelto


sum of first 'n' terms
Given n=10, find the sum of first 'n' terms Example: If n=10, then x=1,2,3,4,5,6,7,8,9,10. The sum of these n=10 terms is 55...

casi 12 años hace

Resuelto


peta to nano (x-ray)
for certain x-ray radiation, given frequency in petahertz, give wavelength in nanometer, must be accurate +/- 25%

casi 12 años hace

Resuelto


Sum the Digits of a Number
Given an integer, sum the digits repeatedly until you end up with a single value less than 10. For example, if you add the di...

casi 12 años hace

Resuelto


Make an awesome ramp for a tiny motorcycle stuntman
Okay, given a vector, say v=[1 3 6 9 11], turn it into a matrix 'ramp' like so: m=[1 3 6 9 11; 3 6 9 11 0; 6 9 ...

casi 12 años hace

Resuelto


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

casi 12 años hace

Resuelto


03 - Matrix Variables 1
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_3a.png>> A 9x9 matrix full of 2's (Hint: use *ones* o...

casi 12 años hace

Resuelto


The Tower of Hanoi
In the <http://en.wikipedia.org/wiki/Tower_of_Hanoi Tower of Hanoi problem> with 3 rods (1, 2 & 3), the goal is to move a tower ...

casi 12 años hace

Resuelto


First non-zero element in each column
For a given matrix, calculate the index of the first non-zero element in each column. Assuming a column with all elements zero ...

casi 12 años hace

Resuelto


DC chopper
Input x is the sampled signal vector, may have both AC and DC components. output vector y should have AC components removed then...

casi 12 años hace

Resuelto


Reverse the Words (not letters) of a String
*Description* Change the words of a string such that the words appear in reverse order. You may assume that the string is a n...

casi 12 años hace

Resuelto


Will there be a new leader?
Simply answer the title.

casi 12 años hace

Resuelto


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

casi 12 años hace

Resuelto


Magic is simple (for beginners)
Determine for a magic square of order n, the magic sum m. For example m=15 for a magic square of order 3.

casi 12 años hace

Resuelto


Generate N equally spaced intervals between -L and L
Given N and L, return a list of numbers (in ascending order) that divides the interval [-L L] into N equal-length segments. F...

casi 12 años hace

Resuelto


Triangle Numbers Below N
This is an offshoot of <http://www.mathworks.com/matlabcentral/cody/problems/5-triangle-numbers Cody Problem 5: Triangle Numbers...

casi 12 años hace

Resuelto


Determine if a Given Number is a Triangle Number
*Description:* Determine if the elements of an input array are triangle numbers and return the result as an array with the sa...

casi 12 años hace

Resuelto


High school cafeteria
Given an input vector of positive integers, return a row vector with the primes first (in increasing order) and the composites n...

casi 12 años hace

Resuelto


Create a vector whose elements depend on the previous element
The idea is to create a vector A whose elements depend on the previous element : *A(i+1) = 2*A(i)+1* *2 Inputs*: - A : The...

casi 12 años hace

Resuelto


Celsius to Fahrenheit converter
Convert Celsius to Fahrenheit degrees.

casi 12 años hace

Resuelto


Is the input divisible by 3?
Return true if the input is divisible by 3 and false if not.

casi 12 años hace

Resuelto


surrounded matrix
With a given matrix A (size m x n) create a matrix B (size m+2 x n+2) so that the matrix A is surrounded by ones: A = [1 2 ...

casi 12 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

casi 12 años hace

Cargar más