Resuelto


IQpuzzler Preparation #1: Find all non-identical 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...

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

2 meses 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),...

2 meses hace

Resuelto


Cluster Partition
Given an array (row or column) of numbers, divide the array into consecutive positive/negative numbers. 0 is to be treated inde...

2 meses hace

Resuelto


Canadian Conundrum
After succesfully completing the French Conundrum, you have decided to take a vacation. Your trip is amongst the mighty mountai...

2 meses hace

Resuelto


French Conundrum
The French army is trapped, sorrounded in backwards direction (South and West directions) by enemy traps and ambushes. You are n...

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

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

2 meses 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)

2 meses 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'.

2 meses hace

Resuelto


Create spiral matrices
Create a matrix of a given size with sequential elements spiraling inward. For matrix height m and width n, the output should ...

2 meses hace

Resuelto


Korselt's Criterion
A composite integer n (n>=2) divides b^n-b, i.e. mod(b^n-b,n)==0, for all integers b if and only if n is square-free (doesn't ha...

2 meses hace

Resuelto


Sum of Consecutive Positive Integers Equals Product of Limiting Values
Determine m and n for the following equation: For example: 3 + 4 + 5 + 6 = 6*3 is the first occurance that satisfies the equat...

2 meses hace

Resuelto


Heronian Triangles with Consecutive Integral Sides and Integral Area
Hero's area formula for any triangle with sides a, b, c is: . Heronian triangles are triangles having integral sides and integr...

2 meses hace

Resuelto


Leonardo primes
Leonardo numbers are defined by following recurrence relation: Leonard prime is Leonardo number which is also prime (see ...

2 meses hace

Resuelto


Area under the curve
Compute area under the curve specified by points stored in y, where y is in range (0,inf) and x time step is 1. note: please r...

2 meses hace

Resuelto


Tracer un carré de côté a et de centre O
Définir une fonction carre qui prend en entrée un salaire a et un vecteur O de deux élements représentant les coordonnées cartés...

2 meses hace

Resuelto


Intrication de deux vecteurs
Ecrire une fonction "intric" qui prend en entrée un vecteur ligne v1 et un vecteur ligne v2 et renvoie le vecteur ligne vres don...

2 meses hace

Resuelto


compter le nombre de zéros dans une matrice
écrire une fonction count_zeros qui prend en entrée une matrice M et détermine le nombre de zéros dans une matrice

2 meses hace

Resuelto


Calculate pi using the Mandelbrot Set.
The Mandelbrot Set is a set of complex numbers built around a simple iterative equation for which the orbit of the critical poin...

2 meses hace

Resuelto


Find the moving-average of the elements of a vector
Example Input vector: [1 2 3 4] output vector: 1st element=1/1, 2nd element=(1+2)/2, 3rd element=(1+2+3)/3, 4th element=(1+2...

2 meses hace

Resuelto


Ordinary Annuity : Number of Payments (Present Value)
Theorem : Present Value of an Ordinary Annuity where; P : Present value of all payments A : Periodic payment r : Interest ...

2 meses hace

Resuelto


Ordinary Annuity : Rate (Present Value)
Theorem : Present Value of an Ordinary Annuity where; P : Present value of all payments A : Periodic payment r : Interest ...

2 meses hace

Resuelto


Ordinary Annuity : Periodic Payment (Present Value)
Theorem : Present Value of an Ordinary Annuity where; P : Present value of all payments A : Periodic payment r : Interest ...

2 meses hace

Resuelto


Ordinary Annuity : Present Value
Theorem : Present Value of an Ordinary Annuity where; P : Present value of all payments A : Periodic payment r : Interest ...

2 meses hace

Resuelto


Ordinary Annuity : Number of payments (Future Value)
Theorem : Future Value of an Ordinary Annuity where; F : Future value A : Periodic payment r : Rate per period n : Numbe...

2 meses hace

Resuelto


Ordinary Annuity : Rate (Future Value)
Theorem : Future Value of an Ordinary Annuity where; F : Future value A : Periodic payment r : Rate per period n : Numbe...

2 meses hace

Resuelto


Ordinary Annuity : Periodic Payments (Future Value)
Theorem : Future Value of an Ordinary Annuity where; F : Future value A : Periodic payment r : Rate per period n : Numbe...

2 meses hace

Resuelto


Ordinary Annuity : Future Value
Theorem : Future Value of an Ordinary Annuity where; F : Future value A : Periodic payment r : Rate per period n : Numbe...

2 meses hace

Resuelto


Compound Interest : Compounding Periods
Theorem : Compound Interest where, F : Future value at the end of n periods P : Present value r : Annual nominal rate n :...

2 meses hace

Cargar más