login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A080791 Number of 0's in binary expansion of n. 17
0, 0, 1, 0, 2, 1, 1, 0, 3, 2, 2, 1, 2, 1, 1, 0, 4, 3, 3, 2, 3, 2, 2, 1, 3, 2, 2, 1, 2, 1, 1, 0, 5, 4, 4, 3, 4, 3, 3, 2, 4, 3, 3, 2, 3, 2, 2, 1, 4, 3, 3, 2, 3, 2, 2, 1, 3, 2, 2, 1, 2, 1, 1, 0, 6, 5, 5, 4, 5, 4, 4, 3, 5, 4, 4, 3, 4, 3, 3, 2, 5, 4, 4, 3, 4, 3, 3, 2, 4, 3, 3, 2, 3, 2, 2, 1, 5, 4, 4, 3, 4, 3, 3, 2, 4 (list; graph; refs; listen; history; internal format)
OFFSET

0,5

COMMENTS

Another version (A023416) has a(0) = 1.

Number of steps required to reach 1, starting at n+1, under the operation: if x is even divide by 2 else add 1. This is the x+1 problem (as opposed to the 3x+1 problem).

LINKS

N. J. A. Sloane, Table of n, a(n) for n = 0..10000

Index entries for sequences related to binary expansion of n

PROG

(PARI) a(n)=if(n<1, 0, a(n\2)+1-n%2)

CROSSREFS

Cf. A023416, A080791-A080801.

Sequence in context: A116382 A050606 A023416 * A124748 A161225 A174980

Adjacent sequences:  A080788 A080789 A080790 * A080792 A080793 A080794

KEYWORD

easy,nonn

AUTHOR

Cino Hilliard (hillcino368(AT)gmail.com), Mar 25 2003

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 16 19:04 EST 2012. Contains 205942 sequences.