Solved

Combination logic

Create an algorithm in MATLAB that calculate the combination for the given positive integers n and k as inputs. When k > n, the ...

6 maanden ago

Solved

What's the missing interior angle?

I'm talking about polygons... The sum of the interior angles of a triangle is 180 degrees. The sum of the interior angles of a...

6 maanden ago

Solved

Can you reshape the matrix?

Given a matrix A, is it possible to reshape it into another matrix with the given number of rows?

6 maanden ago

Solved

Define the operators of function_handles

Suppose f and g are function_handles, try to define f+g,f-g,f*g and f/g. e.g. if f = @(x)x and g = @(x)x+1 ...

6 maanden ago

Solved

sum of ASCII

Given a string x, return the sum of all ASCII numbers of all characters. for example, if x='lala' ('l'-> 108, 'a'->97) then y...

6 maanden ago

Solved

Find third Side of a right triangle given hypotenuse and a side. No * - or other functions allowed

Find the remaining side of a triangle given the hypotenuse and a side. However, the normal functions and symbols are not allowe...

6 maanden ago

Solved

Multiply 2 numbers

Very easy, you just have to multiply 2 numbers but you cannot use the following signs (*, /, - ,^) ,mtimes , times, cross, pro...

6 maanden ago

Solved

Television Screen Dimensions

Given a width to height ratio of a TV screen given as _w_ and _h_ as well as the diagonal length of the television _l_, return t...

6 maanden ago

Solved

Negation the hard way

Write a function that has the following property: f(f(x)) = -x for any numeric array x. Note that there is no restriction on ...

6 maanden ago

Solved

Find the number of days in a given year

Given a year number (eg. 2000) as input, find how many days are there in the given year.

6 maanden ago

Solved

Low level NaN

* I have a dataset. Columns represents different variables. * A variable may start with NaN or any double type number. * If i...

6 maanden ago

Solved

given number is power of n or not?

Check weather The input is power of n or not? for example x=8,n=2 --> true x=6,n=2 --> false

6 maanden ago

Solved

remove nans fast

There are several ways to locate and remove nans in a matrix, and return an 1d row vector. In this problem the challenge is ...

6 maanden ago

Solved

Returning a "greater than" vector

Given a vector, v, return a new vector , vNew, containing only values > n. For example: v=[1 2 3 4 5 6] n=3 vNew =...

6 maanden ago

Solved

Tiling a matrix

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

6 maanden ago

Solved

Sum of logarithms

Given a vector, v, of real positive numbers, compute the sum, s, of the base-10 logarithms of the elements of v, without the use...

6 maanden ago

Solved

Throw common elements of two vector arrays

Throw common elements as output of two given input vector arrays

6 maanden ago

Solved

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

6 maanden ago

Solved

String substitution, sub problem to cryptoMath

This is a sub problem related to this problem: <http://www.mathworks.com/matlabcentral/cody/problems/621-cryptomath-addition>...

7 maanden ago

Solved

Generate a random matrix A of (1,-1)

Input n: is an positive integer which serves as the dimension of the matrix A; Output: A=(Aij),where each entry Aij is either...

7 maanden ago

Solved

How to add?

* Imagine you are in 2222 Anno Domini, when everyone must learn how to add, * and competing for the highly prestigious post of,...

7 maanden ago

Solved

persistant sum

There will be 9 tests for this problem. In each test you will be provided with 2 integers n=[n1,n2], where n2 is equal to t...

7 maanden ago

Solved

Consecutive Powers

Return 2 numbers and 2 powers such that their difference is 1 A 4 element row vector is expected: x where x(1)^x(2) - x(...

7 maanden ago

Solved

Evaluate Polynomial

Given a polynomial equation coefficients in a vector p, you have to return its value at x. Example: For inputs p and x ...

7 maanden ago

Solved

Sum of digits of powers of 2

Given n, first, calculate the number 2^n. Then, sum the digits that comprise that number. For example: Input: n = 7 2^n = ...

7 maanden ago

Solved

Test

Answer the question and the correct answer write in vector. Only one answer is correct. 1a Yes 1b No 1c No 1d No ...

7 maanden ago

Solved

So many choices

For inputs _n_ and _k_ (in that order), output the number of ways that k objects can be chosen from amongst n distinct objects. ...

7 maanden ago