I'm working on modernizing Rosetta Code's infrastructure. Starting with communications. Please accept this time-limited open invite to RC's Slack.. --Michael Mol (talk) 20:59, 30 May 2020 (UTC)

Talk:Sequence: nth number with exactly n divisors

From Rosetta Code

Handy hints[edit]

Handy optimization hints: Terms in position n that is a prime number are always the nth prime raised to the (n-1)th power. E.G.

     # 1  2  3  4  5  6  7  8  9  10  11
primes 2  3  5  7 11 13 17 19 23  29  31
   Term 7  is 17^6  == 24137569. 
   Term 11 is 31^10 == 819628286980801.

and so on.

Non prime odd terms are always a square number. --Thundergnat (talk) 18:53, 11 April 2019 (UTC)

All   odd terms are always a square number.     -- Gerard Schildberger (talk) 01:02, 12 April 2019 (UTC)
You are 100% correct, but these were meant to be optimization hints, not statements of general fact. Sort of an either / or kind of thing. --Thundergnat (talk) 09:59, 12 April 2019 (UTC)
That is one hel heck of some dandy hints!!     -- Gerard Schildberger (talk) 18:56, 11 April 2019 (UTC)

May this is a naive question: Why 2nd term of sequence is not 2 but 3.
2 has exactly 2 divisors: 1 and 2 (CalmoSoft)

2 is the first number with exactly 2 divisors but 3 is the second such number. So, 3 is the second term of the sequence. --PureFox (talk) 13:48, 8 March 2021 (UTC)


Thanks PureFox, now I understand it (CalmoSoft)