OFFSET
1,1
COMMENTS
Computed by Wolfram's 2-state 2-symbol Turing machine 2079 when started with n on the tape.
LINKS
Sean A. Irvine, Table of n, a(n) for n = 1..1000
Stephen Wolfram, P vs. NP and the Difficulty of Computation: A Ruliological Approach, 2026.
MATHEMATICA
a[n_] := BitOr[#, # - 1] &[n + BitAnd[n, -n]]; Array[a, 64] (* Michael De Vlieger, Feb 06 2026 *)
PROG
(PARI) a(n) = my(u=n + bitand(n, -n)); bitor(u, u-1); \\ Michel Marcus, Feb 07 2026
(Python) def a(n): return n + (n & -n) | (n + (n & -n)) - 1 # Aitzaz Imtiaz, Feb 07 2026
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Sean A. Irvine, Feb 04 2026
STATUS
approved
