OFFSET
1,1
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..30030
EXAMPLE
For n = 1, the least prime not dividing it is 2, and the second least prime not dividing is 3, thus a(1) = 3.
For n = 3, the least nondividing prime is 2, the second least nondividing prime is 5, thus a(3) = 5.
For n = 6 = 2*3, the least nondividing prime is 5, and the second least nondividing prime is 7, thus a(6) = 7.
PROG
(PARI) A380539(n) = { my(c=0); forprime(p=2, , if(n%p, c++; if(2==c, return(p)))); };
CROSSREFS
KEYWORD
nonn,new
AUTHOR
Antti Karttunen, Feb 12 2025
STATUS
approved