7 kyu
Array of Primes
475tdowek1
Description:
Your task is to take a given range and return an array of the prime numbers in that range.
You will write a function with the following parameters:
start
is the integer from which your range starts. (inclusive)
end
is the integer at which your range ends. (inclusive)
If the range does not contain any prime numbers return null
.
Examples:
primes(5, 7) // [5, 7]
primes(8, 9) // null
primes(1, 10) // [2, 3, 5, 7]
Fundamentals
Similar Kata:
Stats:
Created | Dec 28, 2015 |
Published | Dec 28, 2015 |
Warriors Trained | 887 |
Total Skips | 32 |
Total Code Submissions | 1600 |
Total Times Completed | 475 |
JavaScript Completions | 475 |
Total Stars | 16 |
% of votes with a positive feedback rating | 89% of 104 |
Total "Very Satisfied" Votes | 83 |
Total "Somewhat Satisfied" Votes | 19 |
Total "Not Satisfied" Votes | 2 |