login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A306392 a(n) = 2^n with 1's and 2's swapped. 2
2, 1, 4, 8, 26, 31, 64, 218, 156, 521, 2014, 1048, 4096, 8291, 26384, 31768, 65536, 232071, 161244, 514188, 2048576, 1097251, 4294304, 8388608, 26777126, 33554431, 67208864, 234127718, 168435456, 536870921, 2073742814, 1247483648, 4194967196 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,1
LINKS
FORMULA
a(n) = A035043(A000079(n)). - Robert Israel, Feb 12 2019
MAPLE
f:= proc(n) local L, i;
L:= subs([2=1, 1=2], convert(2^n, base, 10));
add(L[i]*10^(i-1), i=1..nops(L))
end proc:
map(f, [$0..50]); # Robert Israel, Feb 12 2019
PROG
(Python)
def A306392(n):
return int(''.join('1' if d == '2' else ('2' if d == '1' else d) for d in str(2**n))) # Chai Wah Wu, Feb 12 2019
CROSSREFS
Cf. A000079, A035043, A323948 (sorted version).
Sequence in context: A303632 A133267 A145864 * A182739 A359132 A076014
KEYWORD
nonn,base
AUTHOR
Paul Curtz and N. J. A. Sloane, Feb 12 2019
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 11 19:14 EDT 2024. Contains 372413 sequences. (Running on oeis4.)