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 A338420 #32 Dec 14 2020 23:56:04 %S A338420 2,4,7,8,10,13,15,19,23,25,26,29,31,36,38,40,51,53,55,59,63,71,80,82, %T A338420 84,86,87,99,101,107,109,119,127,128,129,137,143,151,152,155,161,167, %U A338420 169,209,215,227,256,259,260,261,265,266,267,269,271 %N A338420 Numbers k having exactly one base b which is not a divisor of k+1, and k contains the digit b-1 in base b. %C A338420 All the terms of A337536 are in this sequence except A337536(2)=3. %C A338420 There are only 30 terms which are even up to n=124705. %t A338420 baseCount[n_] := Count[Complement[Range[n + 1], Divisors[n + 1]], _?(MemberQ[ IntegerDigits[n, #], # - 1] &)]; Select[Range[1000], baseCount[#] == 1 &] (* _Amiram Eldar_, Oct 25 2020 *) %o A338420 (Python) %o A338420 def A338420(N): %o A338420 return list(filter(isA338420,range(1,N+1))) %o A338420 def isA338420(n): %o A338420 counter=0 %o A338420 if n==2 or n==4: %o A338420 return True %o A338420 if n%2==0: %o A338420 counter=1 %o A338420 for b in range(3,(n//2) +1): %o A338420 if (n+1)%b!=0: %o A338420 counter=main_base_check(int(n/b),b)+counter %o A338420 return counter==1 %o A338420 def main_base_check(m,b): %o A338420 while m!=0: %o A338420 if m%b == b-1: %o A338420 return 1 %o A338420 m = m//b %o A338420 return 0 %o A338420 print(A338420(int(input()))) %o A338420 (PARI) isok(k) = sum(b=2, k+1, ((k+1) % b) && #select(x->(x==b-1), digits(k, b))) == 1; \\ _Michel Marcus_, Oct 30 2020 %Y A338420 Cf. A337536. %K A338420 nonn,base %O A338420 1,1 %A A338420 _Devansh Singh_, Oct 25 2020