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 A337141 #75 Dec 06 2024 01:38:40 %S A337141 6,13,20,27,34,41,42,43,44,45,46,47,48,55,62,69,76,83,90,91,92,93,94, %T A337141 95,96,97,104,111,118,125,132,139,140,141,142,143,144,145,146,153,160, %U A337141 167,174,181,188,189,190,191,192,193,194,195,202,209,216,223,230,237,238,239,240 %N A337141 Numbers having at least one 6 in their representation in base 7. %C A337141 Complementary sequence to A020657. %H A337141 François Marques, <a href="/A337141/b337141.txt">Table of n, a(n) for n = 1..10000</a> %e A337141 33 is not in the sequence since it is 45_7 in base 7, but 34 is in the sequence since it is 46_7 in base 7. %p A337141 seq(`if`(numboccur(6, convert(n, base, 7))>0, n, NULL), n=0..100); %t A337141 Select[ Range[ 0, 100 ], (Count[ IntegerDigits[ #, 7 ], 6 ]>0)& ] %t A337141 Select[Range[300],DigitCount[#,7,6]>0&] (* _Harvey P. Dale_, Dec 23 2020 *) %o A337141 (PARI) isok(m) = #select(x->(x==6), digits(m, 7)) >= 1; %o A337141 (Python) %o A337141 from gmpy2 import digits %o A337141 def A337141(n): %o A337141 def f(x): %o A337141 l = (s:=digits(x,7)).find('6') %o A337141 if l >= 0: s = s[:l]+'5'*(len(s)-l) %o A337141 return n+int(s,6) %o A337141 m, k = n, f(n) %o A337141 while m != k: m, k = k, f(k) %o A337141 return m # _Chai Wah Wu_, Dec 04 2024 %Y A337141 Cf. Numbers with at least one digit b-1 in base b: A074940 (b=3), A337250 (b=4), A337572 (b=5), A333656 (b=6), this sequence (b=7), A337239 (b=8), A338090 (b=9), A011539 (b=10), A095778 (b=11). %Y A337141 Cf. Numbers with no digit b-1 in base b: A005836 (b=3), A023717 (b=4), A020654 (b=5), A037465 (b=6), A020657 (b=7), A037474 (b=8), A037477 (b=9), A007095 (b=10), A171397 (b=11). %K A337141 nonn,base,easy %O A337141 1,1 %A A337141 _François Marques_, Sep 20 2020