Create a Matrix of Zeros
Given an input x, create a square matrix y of zeros with x rows and x columns.
6年弱 前
解決済み
What percentage?
Calculate the output c as the percentage of a on b for given a and b.
6年弱 前
解決済み
Negative matrix
Change the sign of all elements in given matrix.
6年弱 前
解決済み
Back to basics 12 - Input Arguments
Covering some basic topics I haven't seen elsewhere on Cody.
Return a value equal to the number of input arguments to the fun...
6年弱 前
解決済み
Back to basics 10 - Max Float
Covering some basic topics I haven't seen elsewhere on Cody.
Return the largest positive floating-point number MATLAB can han...
6年弱 前
解決済み
Simple equation: Annual salary
Given an hourly wage, compute an annual salary by multiplying the wage times 40 and times 50, because salary = wage x 40 hours/w...
6年弱 前
解決済み
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...
6年弱 前
解決済み
Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise
6年弱 前
解決済み
Say something funny
Say something funny, or not.
Your solution will be (fully automatically and objectively) scored based on how clever or funny ...
6年弱 前
解決済み
Who invented zero?
We know the importance zero in computer science, mathematics... but who invented zero?
Clue:
He was the first in the line ...
6年弱 前
解決済み
03 - Matrix Variables 5
Make the following variable:
<<http://samle.dk/STTBDP/Assignment1_3e.png>>
6年弱 前
解決済み
Count decimal digits of a number
* Given an integer number you have to return the number of its digits.
* For example 248 has 3 digits and 1589 has 4 digits
...
6年弱 前
解決済み
Summation of array
Given an array, Find the sum of all of the elements in it
Examples:
Input x = [1 2 3 5; 4 5 6 7];
Output y is 33
6年弱 前
解決済み
MATCH THE STRINGS (2 CHAR) very easy
Match the given string based on first two characters on each string.
For example
A='harsa';
b='harish'; result '1'
...
6年弱 前
解決済み
Symmetry of vector
Determine whether the vector is symmetric or not (vector could be even or odd in length).
For example:
x = [1 2 3 3 2 1] ...
6年弱 前
解決済み
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...
6年弱 前
解決済み
Replace multiples of 5 with NaN
It is required to replace all values in a vector that are multiples of 5 with NaN.
Example:
input: x = [1 2 5 12 10 7]
...
6年弱 前
解決済み
06 - Matrix Equations 2
Define the vectors _aVec_ and _bVec_:
<<http://samle.dk/STTBDP/Assignment1_2a.png>>
and
<<http://samle.dk/STTBDP/Assig...
Generate a NaN...on purpose
The goal is to create a function that will return a single "NaN" without using the nan function. I am interested to see how many...
6年弱 前
解決済み
square root
Find the square root (y) of an input (x).