Resuelto


Phonebook-like problem
strcmpi('Yes', 'No')

alrededor de 8 años hace

Resuelto


Sum the real and imaginary parts of a complex number
Sum the real and imaginary parts of a complex number. Example c = 1+2i has the solution 1 + 2 = 3

alrededor de 8 años hace

Resuelto


Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]

alrededor de 8 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...

alrededor de 8 años hace

Resuelto


Basics: Divide integers to get integer outputs in all cases
Divide integers a and b in such a way that output y is always an integer (in ceil manner)

alrededor de 8 años hace

Resuelto


Vector Magnitude Calculator
'a' is a vector that starts at the origin and ends at (x, y). Find ||a||. Hint: It is as simple as "ABC".

alrededor de 8 años hace

Resuelto


calculate RMS voltage
given peak to peak voltage, calculate rms voltage

alrededor de 8 años hace

Resuelto


Speed of car
Calculate the Speed of car given its Distance travelled and time taken in x and y respectively

alrededor de 8 años hace

Resuelto


Tiling a matrix
Given a matrix and a number of columns, replicate matrix in a single row

alrededor de 8 años hace

Resuelto


Number of odd and even elements within matrix
Input(m) - any matrix with integers Output(n) - n(1)=number of odd elements, n(2)=number of even elements Example: * m=...

alrededor de 8 años hace

Resuelto


Replace every 3rd element in a vector with 4
x is a vector of undetermined length You are to replace every 3rd element with the number 4, example: x = [11 23 34 43 2 3...

alrededor de 8 años hace

Resuelto


Product of elements in row
Product of matrix such that a=[3 3 1] b=9

alrededor de 8 años hace

Resuelto


Back to Basics - Find no. of elements in a matrix?
Let A be a m*n matrix. Find the total no. of elements in A ? (Hint - formula based) A = [1 2 3;4 5 6]; output = 6

alrededor de 8 años hace

Resuelto


Find the position of first minimum value in an integer array with numbers
If x = [2 6 4 9 10 3 1 5 1] the the output should be 7, because the first minimum value (1) lies at the 7th position.

alrededor de 8 años hace

Resuelto


Find the area of a triangle
Given a triangle with a base b and height h, return the triangle area.

alrededor de 8 años hace

Resuelto


Sum of the Multiplication of Vectors
Given the vectors x and y as input, multiply the vectors and return the summation of its elements. Example: x = [1 2 ...

alrededor de 8 años hace

Resuelto


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

alrededor de 8 años hace

Resuelto


Matlab Basics II - Extract last 3 elements of a vector
Let x be a vector of unknown length, we are always interested in the last 3 numbers in the vector, write a function that gives t...

alrededor de 8 años hace

Resuelto


Output a vector which is table of 9
Output a vector which is table of 9

alrededor de 8 años hace

Resuelto


Sum the squares of numbers from 1 to n
For a given value of n return the sum of square of numbers from 1 to n. Example For n = 2 then sum of squares = 5 (1^2 + ...

alrededor de 8 años hace

Resuelto


"Find out the best cricket"
This is how I originally read Problem 2013, so let's just go with it. Give me the first and last name of the best cricket, rega...

alrededor de 8 años hace

Resuelto


Find Factrorial without using built-in function
A number is given, you have to find the factorial of the number without using built-in factroial function. You may use loops....

alrededor de 8 años hace

Resuelto


square root
Find the square root (y) of an input (x).

alrededor de 8 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...

alrededor de 8 años hace

Resuelto


Test Problem; Create a 5x5 array containing all ones
This is a test for learning the process of creating a Cody problem. The goal of this test problem will be to create an array,...

alrededor de 8 años hace

Resuelto


Remove the positive integers.
Given array,x, remove all the positive numbers and display ouput as y. Example x=[1 -2 3 -4] , output is y=[-2 -4].

alrededor de 8 años hace

Resuelto


Find nth maximum
Find nth maximum in a vector of integer numbers. Return NaN if no such number exists. x = [2 6 4 9 -10 3 1 5 -10]; So ...

alrededor de 8 años hace

Resuelto


factorial of a number x
Factorial of a number x

alrededor de 8 años hace

Resuelto


Matlab Basics II - Max & Index of Max
Write a function that takes a vector x, then returns both the max value in x and its location in the vector for example x ...

alrededor de 8 años hace

Resuelto


Matlab Basics II - Velocity of a particle
A particle is moving in space, such that it's velocity is given by: <<http://s30.postimg.org/5rf1xtvj5/cody1.png>> write a...

alrededor de 8 años hace

Cargar más