cp's OEIS Frontend

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.

A346904 Numbers with sum of digits equaling 17, divisible by 17, and containing the string "17".

Original entry on oeis.org

13175, 15317, 17153, 17306, 17612, 21743, 30617, 41174, 51731, 61217, 101762, 107117, 110177, 111707, 117062, 117215, 117521, 122417, 125171, 131750, 153017, 153170, 170153, 170306, 170612, 171071, 171224, 171530, 172142, 172601, 173060, 173213, 174131, 175202, 176120, 214217
Offset: 1

Views

Author

Tanya Khovanova, Aug 06 2021

Keywords

Examples

			13175 contains 17 as a substring; the sum of digits of 13175 is 17, and 13175 is divisible by 17. Thus, 13175 is in this sequence.
		

Crossrefs

Cf. A121669 (for 19 instead of 17).
Intersection of A008599, A166370, and A293877

Programs

  • Mathematica
    d17Q[n_] := Module[{idn = IntegerDigits[n]}, Total[idn] == 17 && MemberQ[Partition[idn, 2, 1], {1, 7}]]; Select[17*Range[20000], d17Q]
  • Python
    def ok(n): s = str(n); return n%17==0 and '17' in s and sum(map(int, s))==17
    print(list(filter(ok, range(214218)))) # Michael S. Branicky, Aug 06 2021