Tagged Questions
12
votes
19answers
873 views
Give the smallest number that has N divisors
Your function takes a natural number and returns the smallest natural number that has exactly that amount of divisors, including itself.
Exemples:
f(1) = 1 [1]
f(2) = 2 [1, 2]
f(3) = 4 [1, 2, 4]
...
12
votes
5answers
709 views
Find largest prime which is still a prime after digit deletion
Over at http://math.stackexchange.com/questions/33094/deleting-any-digit-yields-a-prime-is-there-a-name-for-this the following question is asked. How many primes are there that remain prime after you ...
1
vote
2answers
224 views
List ALL prime-factorized natural numbers in ANY order
This is a variant of List prime-factorized natural numbers up to N in ascending order, but the solutions can be very different.
Write a program that outputs prime factorizations of all natural ...
2
votes
2answers
262 views
List prime-factorized natural numbers up to N in ascending order
For a given n list prime factorization of all natural numbers between 1 and n in ascending order. For example, for n = 10 the output would be:
1:
2: 2^1
3: 3^1
4: 2^2
5: 5^1
6: 2^1 3^1
7: 7^1
8: 2^3
...
4
votes
7answers
593 views
Find the nth Fibonnaci Prime, in the shortest code
The challenge is rather simple:
Take a positive whole number n as input.
Output the nth Fibonacci prime number.
Input can be as an parameter to a function (and the output will be the return ...
0
votes
3answers
293 views
Prime tester + nth-prime finder (TO BE CLOSED) [duplicate]
Possible Duplicate:
List of first n prime numbers most efficiently and in shortest code
This is to be closed soon - please don't answer (mod- please close!)
This challenge is to write the ...
2
votes
5answers
489 views
Show Ulam's spiral
Similar to this but in this one you need to write spiral starting from the center where:
space means composite number
.(dot) means prime number.
Size of the spiral can be given as parameter or on ...