Resuelto


Max index of 3D array
Given a three dimensional array M(m,n,p) write a code that finds the three coordinates x,y,z of the Maximum value. Example ...

casi 5 años hace

Resuelto


Making change
Given an amount of currency, return a vector of this form: [100 50 20 10 5 2 1 0.5 0.25 0.1 0.05 0.01] Example: Input a = ...

casi 5 años hace

Resuelto


Set some matrix elements to zero
First get the maximum of each *row*, and afterwards set all the other elements to zero. For example, this matrix: 1 2 3 ...

casi 5 años hace

Resuelto


Balanced number
Given a positive integer find whether it is a balanced number. For a balanced number the sum of first half of digits is equal to...

casi 5 años hace

Resuelto


Program an exclusive OR operation with logical operators
Program an exclusive or operation *without* using the MATLAB function xor. Use logical operators like |, &, ~, ... instead. ...

casi 5 años hace

Resuelto


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for.

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

casi 5 años hace

Resuelto


Colon operator of two vectors
You are given two vectors of equal length: VecStart, VecEnd Each vector contain a set of integers, where VecEnd(j)>=VecStar...

casi 5 años hace

Resuelto


Make a Palindrome Number
Some numbers like 323 are palindromes. Other numbers like 124 are not. But look what happens when we add that number to a revers...

casi 5 años hace

Resuelto


Divisors of an integer
Given a number N, return a vector V of all integers that divide N. For example, N = 10 Then V=[1 2 5 10]

casi 5 años hace

Resuelto


Find out value of sine given by degree.
Find out value of sine given by degree. If theta=30, it's value must be 0.5.

casi 5 años hace

Resuelto


Element by element multiplication of two vectors
Given two input vectors, return the element-by-element product. Example A = [1 2 3] B = [7 3 1] The answer should be...

casi 5 años hace

Resuelto


Try and Catch Simple Example
Try and Catch Simple Example <http://in.mathworks.com/help/matlab/ref/try.html Example> Vector x=[1 4 6 8 10]; Create...

casi 5 años hace

Resuelto


Find out total non zero element of matrix
Find out Non zero element of matrix A=magic(5) 17 24 1 8 15 23 5 7 14 16 4 6...

casi 5 años hace

Resuelto


Calculate the number of elements in a matrix.
Calculate the number of elements in a matrix.

casi 5 años hace

Resuelto


Determine the factorial of a number

casi 5 años hace

Resuelto


Area of Ellipse

casi 5 años hace

Resuelto


Area of a pentagon
Given the side of a regular pentagon and its apothem return the area of pentagon. Remember the area of pentagon is calculate ...

casi 5 años hace

Resuelto


Make a vector of prime numbers
Input(n) - length of vector with prime numbers Output(v) - vector of prime numbers Example: * n=1; v=2 * n=3; v=[2 3 5...

casi 5 años hace

Resuelto


Perimeters/Circumference
Given an array. Determine whether the perimeter is of a circle, triangle or square. Then calculate the perimeter.

casi 5 años hace

Resuelto


Skip by a multiple
Given an integer create an array of its multiples. Array must have a length of 15

casi 5 años hace

Resuelto


Product of Array
Given an array of numbers. Get the product of the array.

casi 5 años hace

Resuelto


Remove the Zero
Given an array n, remove all zeros

casi 5 años hace

Resuelto


Where is she?
Given the numbers 12, 3, 6, 9 Tell where the girl is located. That is: Look to your 3 o'clock = look right Example ...

casi 5 años hace

Resuelto


Remove and Sort
Given a randomized array n, sort it and remove all odd integers. n=5 y = [2 4]

casi 5 años hace

Resuelto


Is It a Palindrome?
Given a string or array, determine if it is a palindrome.

casi 5 años hace

Resuelto


Kinetic Energy
Given the mass m and velocity v of an object, determine its <http://en.wikipedia.org/wiki/Kinetic_energy kinetic energy>.

casi 5 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 5 años hace

Resuelto


Distance Between Points
Being n the number of points (If n = 3 there would be 3 points: A, B and C). The distance between each pair of points increases...

casi 5 años hace

Resuelto


Find the area of ​​the square
There are *n²* circles inscribed in the square ABCD. The perimeter of each circle is *aπ* <<http://imgfz.com/i/3wzCeAT.png>> ...

casi 5 años hace

Cargar más