Resuelto


Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displayed ...

11 meses hace

Resuelto


Generate a vector like 1,2,2,3,3,3,4,4,4,4
Generate a vector like 1,2,2,3,3,3,4,4,4,4 So if n = 3, then return [1 2 2 3 3 3] And if n = 5, then return [1 2 2 3 3 3 4...

11 meses hace

Resuelto


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

11 meses hace

Resuelto


Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the numbers. Otherwise return false. Example...

11 meses hace

Resuelto


Find the summation of factorial series
Factorial numbers are n! = 1*2*3....*n the series is 1!, 2!, 3!,........, n!

11 meses hace

Resuelto


Return area of square
Side of square=input=a Area=output=b

11 meses hace

Resuelto


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.

11 meses hace

Resuelto


Add two numbers
Given a and b, return the sum a+b in c.

11 meses hace

Resuelto


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

11 meses hace

Resuelto


Flipping
Write code that can reverse the vector without using any sort of loop. Example Given the input vector A = [ 1 2 3 4 5...

11 meses hace

Resuelto


Flip the diagonal values
Write a program that flip the elements of main diagonal , upper and lower diagonal values of a sqare matrix. For example if a ...

11 meses hace

Resuelto


Flip the bit
Given an input character string (e.g. '1001'), return a character string with the bits flipped ('0110').

11 meses hace

Resuelto


Flipping a Matrix
Flipping matrix up and down. If a central row is exists, leave it, and flip remaining rows. Example Mat = magic(3) ...

11 meses hace

Resuelto


Is A the inverse of B?
Given a matrix A and a matrix B, is A the inverse of B? >>A=[2,4;3,5]; >>B=[-2.5,2;1.5,-1]; >>isInverse...

11 meses hace

Resuelto


Rotate Matrix @180 degree
Rotate Matrix @180 degree Example A=[8 1 6; 3 5 7; 4 9 2], then answer would be [2 9 4;...

11 meses hace

Resuelto


Converts numbers into characters
Converts numbers into characters

11 meses hace

Resuelto


Find the max element of the array
Find the max element of the array

11 meses hace

Resuelto


Square root
Given x (a matrix), give back another matrix, where all the elements are the square roots of x's elements.

11 meses hace

Resuelto


Calculate the average value of the elements in the array
Calculate the average value of the elements in the array

11 meses hace

Resuelto


to the 2 all elements
to the 2 all elements

11 meses hace

Resuelto


the average value of the elements
Calculate the average value of the elements in the array

11 meses hace

Resuelto


Double all elements in the array
Duplicate all elements in the array

11 meses hace

Resuelto


calculate the length of matrix
input 1 array, calculate the length

11 meses hace

Resuelto


Draw a '0' in a one matrix!

11 meses hace

Resuelto


swap sign sum & multiply castles
It is an easy problem, if you know the answer. Given a square matrix of NxN ordinary numbers. Initially place N identical indi...

11 meses hace

Resuelto


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

11 meses hace

Resuelto


Half-Swap
Given a vector with an even number of elements, rearrange it so that the elements in its first half are switched with those i...

11 meses hace

Resuelto


Matlab Basics - Switching Assignments
Switch assignments for variables x and y, for example start with x = 1 and y = 3 end with y = 1 and x = 3 Do NOT simply r...

11 meses hace

Resuelto


Swap between columns
The idea is to swap between second and second last column Ex = [1 2 3 4 5; 1 2 3 4 5; 1 2 3 4 5; 1 2 3 4 5; ...

12 meses hace

Resuelto


Remove a specific character with another
Remove any (-) dash sign with (_) underscore Ex = 'The-Journey-of-thoudsands-miles-starts-with-a-single-step' y = 'The_Jour...

12 meses hace

Cargar más