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.

Showing 1-3 of 3 results.

A048401 Primes with consecutive digits that differ exactly by 4.

Original entry on oeis.org

2, 3, 5, 7, 37, 59, 73, 151, 373, 15959, 95959, 515951, 595159, 595951, 9515959, 51515159, 159595151, 159595951, 5151515951, 5159515159, 5159515951, 5951515151, 5951515951, 5959515151, 5959595951, 15151595951, 15951515159
Offset: 1

Views

Author

Patrick De Geest, Apr 15 1999

Keywords

Crossrefs

Programs

  • Mathematica
    pd[{a_,b_,c___}]:=Flatten[Table[Select[FromDigits/@Select[Tuples[ {a,b,c},n],Union[Abs[Differences[#]]]=={4}&],PrimeQ],{n,11}]]; Union[Join[{2,3,5,7},pd[{1,5,9}],pd[{3,7}]]] (* Harvey P. Dale, Aug 23 2011 *)

Extensions

More terms from Naohiro Nomoto, Jul 28 2001

A048407 Numbers whose consecutive digits differ by 5.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 16, 27, 38, 49, 50, 61, 72, 83, 94, 161, 272, 383, 494, 505, 616, 727, 838, 949, 1616, 2727, 3838, 4949, 5050, 6161, 7272, 8383, 9494, 16161, 27272, 38383, 49494, 50505, 61616, 72727, 83838, 94949, 161616, 272727, 383838
Offset: 0

Views

Author

Patrick De Geest, Apr 15 1999

Keywords

Crossrefs

Programs

  • Mathematica
    Join[Range[0,9],Select[Range[400000],Union[Abs[Differences[ IntegerDigits[ #]]]] == {5}&]] (* Harvey P. Dale, Sep 23 2013 *)

A198486 Numbers with the property that all pairs of consecutive digits differ by 9.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 90, 909, 9090, 90909, 909090, 9090909, 90909090, 909090909, 9090909090, 90909090909, 909090909090, 9090909090909, 90909090909090, 909090909090909, 9090909090909090, 90909090909090909, 909090909090909090, 9090909090909090909
Offset: 1

Views

Author

Pieter Stadhouders, Oct 20 2013

Keywords

Crossrefs

Programs

  • Mathematica
    t = {1, 2, 3, 4, 5, 6, 7, 8, 9}; Do[AppendTo[t, 10*t[[-1]]]; AppendTo[t, 10*t[[-1]] + 9], {9}]; t (* T. D. Noe, Oct 22 2013 *)
  • Python
    def A198486():
        print('Numbers whose consecutive digits differ by 9')
        for i in range(1, 100001):
            b, n = True, i
            if n > 9:
                while n > 9:
                    a = abs((n // 10) % 10 - n % 10)
                    if a != 9: b = False
                    n = n // 10
            if b: print(i, end=', ')
        return

Extensions

More terms from T. D. Noe, Oct 22 2013
Showing 1-3 of 3 results.