This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A249876 #22 Feb 26 2024 19:17:25 %S A249876 1,3,5,7,11,13,17,21,23,25,31,35,41,43,45,47,55,57,63,65,73,75,83,87, %T A249876 95,97,101,105,107,113,123,127,131,133,141,143,147,151,153,161,175, %U A249876 177,183,185,197,201,211,213,215,217,227,233,235,237,251,255,265,267 %N A249876 Pseudo-lucky numbers. %C A249876 Appears to grow more slowly than the Lucky numbers. - _Jon Perry_, Nov 07 2014 %H A249876 Jean-François Alcover, <a href="/A249876/b249876.txt">Table of n, a(n) for n = 1..1000</a> %e A249876 Start with the natural numbers. The 2nd number is 2, so delete every 2nd number, leaving 1 3 5 7 9 11 13 15 17 19...; the 3rd number remaining is 5, so delete every 5th number, leaving 1 3 5 7 11 13 15 17 ...; now delete every 7th number, leaving 1 3 5 7 11 13 17 ...; now delete every 11th number; etc. %p A249876 L:= [seq(i, i=1..10^3)]: %p A249876 for n from 2 while n < nops(L) do %p A249876 r:= L[n]; %p A249876 L:= subsop(seq(r*i=NULL, i=1..nops(L)/r), L); %p A249876 od: %p A249876 L; %t A249876 FixedPoint[Function[{L}, n++; Delete[L, List /@ (L[[n]]*Range[Quotient[Length[L], L[[n]] ]])]], n=1; Range[1000]] (* _Jean-François Alcover_, Nov 27 2014 *) %o A249876 (Python) %o A249876 def listed(n): %o A249876 L=list(range(1,n+1));j=1 %o A249876 while L[j] <= len(L): %o A249876 L=[L[i] for i in range(len(L)) if (i+1)%L[j]!=0] %o A249876 j+=1 %o A249876 return(L) %Y A249876 Cf. A000959 (Lucky numbers). %K A249876 nonn %O A249876 1,2 %A A249876 _Robert FERREOL_, Nov 07 2014