Resuelto

Cricket - Career Bowling Statistics
Given a vector s of strings representing a bowler's individual innings records, return their career statistics as a 3-element (n...

24 días hace

Resuelto

Cricket - Report the Result (Part I: Limited Overs)
Given two scalar strings representing the scores for a limited-overs match, return a string reporting the result in the form "Te...

24 días hace

Resuelto

Cricket - Peak Batting Average
Given a vector s of strings representing a batter's individual innings scores (in chronological order), return the highest batti...

24 días hace

Resuelto

Cricket - Represent Average in "Dulkars" and "Ses"
Sachin Tendulkar's Test average was 53.78. So if Tendulkar = 53.78, one dulkar = 5.378. Similarly, Roger Twose's average was 25....

25 días hace

Resuelto

Cricket - Career Batting Statistics
Given a vector s of strings representing a batter's individual innings scores, return their career statistics as a 4-element (nu...

25 días hace

Resuelto

Cricket - How Much More to Beat Bradman?
Sir Don Bradman famously needed only 4 runs in his final innings to retire with an average of 100. Out for a duck, he ended inst...

25 días hace

Resuelto

Cricket - Average Partnership Contribution
The (infamous) Duckworth-Lewis method uses statistical models of how much each wicket partnership is worth to an innings (on ave...

26 días hace

Resuelto

IQpuzzler Preparation #1: Find all possible orientations of a matrix
Return all non-identical orientations of a 2-D matrix that can be produced by rotating or flipping it. Input is an M-by-N matri...

26 días hace

Resuelto

nth permutation of 11...100...0
Given some number of ones and zeros, numOnes and numZeros respectively, find the nth permutation of the vector [ones(1,numOnes),...

29 días hace

Resuelto

Multiply each matrix element by its row index and add its column index.
Return a matrix the same size as the input, multiply each element by its row index and add its column index. Example: x = [ 1 ...

29 días hace

Resuelto

Easy Sequences 78: Trailing Zeros of Factorial Numbers at any Base
Given an integer and a number base , write a function that calculates the number of trailing zeros of the factorial of when wr...

alrededor de 1 mes hace

Resuelto

Triangle Coordinates
Given a natural number n, return two -element vectors, x and y, containing the coordinates of a triangular arrangement of points...

alrededor de 1 mes hace

Resuelto

Possible Rugby Scores
Given a natural number s (> 4), representing a rugby team's score, return an n-by-3 matrix representing all n possible combinati...

alrededor de 1 mes hace

Resuelto

Extract the Acrostic Message
An acrostic cipher is a way of embedding one message within another by taking the first (or last) word of each line. Given a str...

alrededor de 1 mes hace

Resuelto

Angle Between Analog Clock Hands
Given a datetime variable t, return the angle (in degrees) between the hour and minute hands of an analog clock at the time repr...

alrededor de 1 mes hace

Resuelto

Split Even Number Into Two Primes
Given an even whole number n (> 2), return a 2-element vector of primes, p, such that p(1) + p(2) = n. Fun note: technically it...

alrededor de 1 mes hace

Resuelto

Create block matrix of integers (j+k-1) - Part II
Given m, n, p, and q, create an m-by-n matrix made up of submatrices, each sized p-by-q (if possible - the last row and column o...

alrededor de 1 mes hace

Resuelto

Create block matrix of integers (j+k-1) - Part I
Given m, n, p, and q, create a matrix of m-by-n blocks (submatrices), each sized p-by-q. The elements of the (j,k)th block all h...

alrededor de 1 mes hace

Resuelto

Determine if Input is Oddish or Evenish (Odd/Even Sum of Digits)
Given a positive integer n, determine whether n is "oddish" or "evenish" - that is, whether the sum of the digits of n is odd or...

alrededor de 1 mes hace

Resuelto

Boustrophedon
Given a vector v and a positive integer n, return an m-by-n matrix containing the elements of v row-wise, alternating left-to-ri...

alrededor de 1 mes hace

Resuelto

Dartboard Average II
A dartboard arranges the numbers 1 to 20 such that each value is typically flanked by quite different values - for example, 20 i...

alrededor de 1 mes hace

Resuelto

Dartboard Average I
A dartboard arranges the numbers 1 to 20 such that each value is typically flanked by quite different values - for example, 20 i...

alrededor de 1 mes hace

Resuelto

how to determine is a point is inside, on or outside a polygon?
design function determines whether the point is inside a contour, outside, or lies on an edge (or coincides with a vertex). It r...

alrededor de 1 mes hace

Resuelto

Zero or hero
A number will be given as an input. You can be hero if it's not zero. (Just for fun)

alrededor de 1 mes hace

Resuelto

Identifying teenager
Suppose the age of a person is given. If he/she is a teenage, answer is 'yes'. Otherwise, the answer is 'no'.

alrededor de 1 mes hace

Resuelto

Taylor Series
You can use a Taylor series to approximate common functions. The Taylor series for sin(x) is Using only the first several te...

alrededor de 2 meses hace

Resuelto

Interpolated Value Between Two Points
Given two points, and , a new location x, and a method "linear" or "cubic", return the value of a linear or cubic interpolant t...

alrededor de 2 meses hace

Resuelto

Generate Pascal's Triangle Matrix
Pascal's triangle is an arrangement of numbers where each value is the sum of the values adjacent to it in the previous row: ...

alrededor de 2 meses hace

Resuelto

Estimating Euler's (Oi-ler-z) Number
Euler's number is an irrational constant given by Starting with x=0, count the number of times you can add a uniformly distrib...

alrededor de 2 meses hace

Resuelto

Generate Tribonacci Sequence
The "Tribonacci" sequence is an extension of the idea of the Fibonacci sequence: That is, each new term is the sum of the thr...

alrededor de 2 meses hace