David Legrand
Followers: 0 Following: 0
Statistiche
0 Problemi
62 Soluzioni
RANK
N/A
of 289.945
REPUTAZIONE
N/A
CONTRIBUTI
0 Domande
0 Risposte
ACCETTAZIONE DELLE RISPOSTE
0.00%
VOTI RICEVUTI
0
CONTRIBUTI
0 Post
CONTRIBUTI
0 Pubblico Canali
VALUTAZIONE MEDIA
CONTRIBUTI
0 Punti principali
NUMERO MEDIO DI LIKE
Feeds
Risolto
De-primed
Write a function that will multiply every prime number in the array or matrix by two, leaving all other numbers the same, and re...
quasi 5 anni fa
Risolto
Find out the Gray Code for a Given Binary Number
Find out <http://en.wikipedia.org/wiki/Gray_code Gray Code> for a given binary number Example Binary input 1000 Gray ...
quasi 5 anni fa
Risolto
Is it an Armstrong number?
An Armstrong number of three digits is an integer such that the sum of the cubes of its digits is equal to the number itself. Fo...
quasi 5 anni fa
Risolto
Happy 2013...
Happy 2013, everyone! An interesting tidbit about 2013 is that it is the first year since 1987 to contain four different digits...
quasi 5 anni fa
Risolto
Determine if input is a Narcissistic number
<http://en.wikipedia.org/wiki/Narcissistic_number Narcissistic number> is a number that is the sum of its own digits each raised...
quasi 5 anni fa
Risolto
Project Euler: Problem 9, Pythagorean numbers
A Pythagorean triplet is a set of three natural numbers, a b c, for which, a^2 + b^2 = c^2 For example, 3^2 + 4^2 =...
quasi 5 anni fa
Risolto
First N Perfect Squares
*Description* Return the first N perfect squares *Example* input = 4; output = [ 1 4 9 16 ];
quasi 5 anni fa
Risolto
Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...
circa 5 anni fa
Risolto
Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...
circa 5 anni fa
Risolto
Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man? Give the name of that man, who, by popular believe, can ...
circa 5 anni fa
Risolto
Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...
circa 5 anni fa
Risolto
Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...
circa 5 anni fa
Risolto
Get the length of a given vector
Given a vector x, the output y should equal the length of x.
circa 5 anni fa
Risolto
Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...
circa 5 anni fa
Risolto
Get all prime factors
List the prime factors for the input number, in decreasing order. List each factor. If the prime factor occurs twice, list it as...
circa 5 anni fa
Risolto
Project Euler: Problem 3, Largest prime factor
The prime factors of 13195 are 5, 7, 13 and 29. What is the largest prime factor of the number being input, input might be ui...
circa 5 anni fa
Risolto
Prime factor digits
Consider the following number system. Calculate the prime factorization for each number n, then represent the prime factors in a...
circa 5 anni fa
Risolto
Determine if input is odd
Given the input n, return true if n is odd or false if n is even.
circa 5 anni fa
Risolto
Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Examp...
circa 5 anni fa
Risolto
Find the biggest empty box
You are given a matrix that contains only ones and zeros. Think of the ones as columns in an otherwise empty floor plan. You wan...
circa 5 anni fa
Risolto
Number of Even Elements in Fibonacci Sequence
Find how many even Fibonacci numbers are available in the first d numbers. Consider the following first 14 numbers 1 1 2...
circa 5 anni fa
Risolto
Project Euler: Problem 2, Sum of even Fibonacci
Each new term in the Fibonacci sequence is generated by adding the previous two terms. By starting with 1 and 2, the first 10 te...
circa 5 anni fa
Risolto
Find the next Fibonacci number
In the sequence of Fibonacci numbers, every number is the sum of the two preceding ones: 1, 1, 2, 3, 5, 8, 13, 21, 34, 55...
circa 5 anni fa
Risolto
Return fibonacci sequence do not use loop and condition
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: ...
circa 5 anni fa
Risolto
Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...
circa 5 anni fa
Risolto
Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...
circa 5 anni fa
Risolto
Converting binary to decimals
Convert binary to decimals. Example: 010111 = 23. 110000 = 48.
circa 5 anni fa
Risolto
Bit Reversal
Given an unsigned integer _x_, convert it to binary with _n_ bits, reverse the order of the bits, and convert it back to an inte...
circa 5 anni fa