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.

A055126 Base-16 complement of n (write n in base 16, then replace each digit with its base-16 negative).

Original entry on oeis.org

0, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 240, 255, 254, 253, 252, 251, 250, 249, 248, 247, 246, 245, 244, 243, 242, 241, 224, 239, 238, 237, 236, 235, 234, 233, 232, 231, 230, 229, 228, 227, 226, 225, 208, 223, 222, 221, 220, 219, 218, 217, 216, 215
Offset: 0

Views

Author

Henry Bottomley, Apr 19 2000

Keywords

Crossrefs

Column k=16 of A248813.

Programs

  • Haskell
    a055126 0 = 0
    a055126 n = if d == 0 then 16 * a055126 n' else 16 * a055126 n' + 16 - d
                where (n', d) = divMod n 16
    -- Reinhard Zumkeller, Mar 12 2014