Risolto


Multiply by 3
Given the variable x as your input, multiply it by three and put the result in y.

circa 10 anni fa

Risolto


Swap two numbers
Example Input: a = 10 b = 20 Output a = 20 b = 10

circa 10 anni fa

Risolto


Is it an Armstrong number?
An Armstrong number of three digits is an integer such that the sum of the cubes of its digits is equal to the number itself. Fo...

circa 10 anni fa

Risolto


Positive Infinity
Round the array a towards positive infinity

circa 10 anni fa

Risolto


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

circa 10 anni fa

Risolto


Deleting an element in a matrix
For vector Grades=[98 56 78 34 100 88 87], delete the number 78 to get the following matrix Grades=[98 56 34 100 88 87] **re...

circa 10 anni fa

Risolto


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

circa 10 anni fa

Risolto


Calculate volume of box
Calculate the volume of box,hiven its sides

circa 10 anni fa

Risolto


Leap Year
According to Gregorian Calender(which is in use now, in many countries),decide whether a given year is a leap year or not. Give...

circa 10 anni fa

Risolto


How many rectangles in a grid ?
How many rectangles are there in an m × n grid ? For example, if m=1 & n=2, we have 3 rectangles.

circa 10 anni fa

Risolto


Write a function man that takes a row vector v and returns a matrix H as follows..
Write a function called man that takes a row vector v as an input and returns a matrix H whose first column consist of the eleme...

circa 10 anni fa

Risolto


Compare two input matrices
Check which input matrix has more elements. Return "1" if matrix A has more elements than matrix B. Otherwise return "0". Exa...

circa 10 anni fa

Risolto


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

circa 10 anni fa

Risolto


Matlab Basics - Convert a row vector to a column vector
Write a script to convert a row (e.g. x = [1 2 3]) to a column (e.g. y = [1;2;3]), your script should be able to do this for any...

circa 10 anni fa

Risolto


Switch matrix to a column vector
for e.g. x = [1 2 3 4] y = 1 3 2 4

circa 10 anni fa

Risolto


Reverse a matrix
Its simple. You have to reverse a given matrix.

circa 10 anni fa

Risolto


Insert zeros into vector
Insert zeros after each elements in the vector. Number of zeros is specified as the input parameter. For example: x = [1 ...

circa 10 anni fa

Risolto


Given a 4x4 matrix, swap the two middle columns
If a = [1 2 3 4; 1 2 3 4; 1 2 3 4; 1 2 3 4]; then the result is ans = 1 3 2 4 1 3 2...

circa 10 anni fa

Risolto


Maximum value in a matrix
Find the maximum value in the given matrix. For example, if A = [1 2 3; 4 7 8; 0 9 1]; then the answer is 9.

circa 10 anni fa

Risolto


Number of digits in an integer
Specifies how many digits in a given integer. Example: in=100 ==> out=3

circa 10 anni fa

Risolto


length of a vector
Find twice the length of a given vector.

circa 10 anni fa

Risolto


03 - Matrix Variables 2
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_3b.png>> A 9x9 matrix of zeros, but with the following v...

circa 10 anni fa

Risolto


Output any real number that is neither positive nor negative
Output any real number that is neither positive nor negative

circa 10 anni fa

Risolto


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

circa 10 anni fa

Risolto


Concatenating arrays
* Assign studentIDs with concatenated row arrays groupA and groupB

circa 10 anni fa

Risolto


Declaring a string
* Assign streetAddress with the string 1313 Mockingbird Lane.

circa 10 anni fa

Risolto


Number of Horns on a unicorn!
Calculate the number of horns on a *unicorn*! And I'm talking about a unicorn with not more than one horn on it!

circa 10 anni fa

Risolto


Solve the Sudoku Row
*Description* A simple yet tedious task occurs near the end of most Sudoku-solving algorithms, computerized or manual. The ta...

circa 10 anni fa

Risolto


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

circa 10 anni fa

Risolto


Check if equal
Return true if all the elements of an nD array are equal, false otherwise.

circa 10 anni fa

Carica altro