Resuelto


Recurrence relation
A recurrence relation is given by P(1) := 1 P(n+1) := exp(1) - (n+1)*P(n) Write a function that, given an integer |...

más de 10 años hace

Resuelto


Back to basics - array operations
Without performing actual arithmetic operations on arrays, return feasibility of operation as true or false. True if given opera...

más de 10 años hace

Resuelto


Replace secondary diagonal elements of a square array
Replace all the secondary diagonal elements of the square array A with the number n Example: A = [1 2 3 4 5 6 ...

más de 10 años hace

Resuelto


Remove all the words that end with "ain"
Given the string s1, return the string s2 with the target characters removed. For example, given s1 = 'the main event' your ...

más de 10 años hace

Resuelto


interesting center of magic matrix
output the centre of magic matrix of n input=7; output=25

más de 10 años hace

Resuelto


Is the Point in a Triangle?
Check whether a point or multiple points is/are in a triangle with three corners Points = [x, y]; Triangle = [x1, y1; x...

más de 10 años hace

Resuelto


Pattern matching
Given a matrix, m-by-n, find all the rows that have the same "increase, decrease, or stay same" pattern going across the columns...

más de 10 años hace

Resuelto


Sums with Excluded Digits
Add all the integers from 1 to n in which the digit m does not appear. m will always be a single digit integer from 0 to 9. no...

más de 10 años hace

Resuelto


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

más de 10 años hace

Resuelto


Counting Money
Add the numbers given in the cell array of strings. The strings represent amounts of money using this notation: $99,999.99. E...

más de 10 años hace

Resuelto


Quote Doubler
Given a string s1, find all occurrences of the single quote character and replace them with two occurrences of the single quote ...

más de 10 años hace

Resuelto


Perimeter
Given a sequence of points forming a closed path (first and last points are coincident) return the perimeter value. For example...

más de 10 años hace

Resuelto


Largest Twin Primes
<http://en.wikipedia.org/wiki/Twin_prime Twin primes> are primes p1, p2 = p1 + 2 such that both p1 and p2 are prime numbers. Giv...

más de 10 años hace

Resuelto


Mersenne Primes
A Mersenne prime is a prime number of the form M = 2^p - 1, where p is another prime number. For example, 31 is a Mersenne prim...

más de 10 años hace

Resuelto


N-Cards Problem
You have a deck of _N_ cards numbered in order from 1 to _N_. You discard the top card (card 1) and place the next card (card 2)...

más de 10 años hace

Resuelto


Poker Series 11: selectBestHand
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


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

más de 10 años hace

Resuelto


Poker Series 10: bestHand
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 09: IsHighCard
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 07: IsTwoPair
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 08: IsPair
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 06: isThreeKind
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 03: isFullHouse
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 02: isQuads
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is to...

más de 10 años hace

Resuelto


Poker Series 01: isStraightFlush
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 04: isFlush
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Poker Series 05: isStraight
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

más de 10 años hace

Resuelto


Clock Hand Angle 1
Given a time in HH:MM:SS, find the smallest angle (in degrees) between the hour and minute hand

más de 10 años hace

Resuelto


Angles of the hands of a clock
For this problem, consider an analog (or at least continuous digital representation) of a clock. Our clock is a 12 hour clock w...

más de 10 años hace

Resuelto


Angle between Two Vectors
The dot product relationship, a dot b = | a | | b | cos(theta), can be used to determine the acute angle between vector a and ve...

más de 10 años hace

Cargar más