The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A165634 Start with x=1 and repeat: if x is a prime number then (append i and then x, with x=prime(i)) else (only append x), continue with x:=x+1. 3
 1, 1, 2, 2, 3, 4, 3, 5, 6, 4, 7, 8, 9, 10, 5, 11, 12, 6, 13, 14, 15, 16, 7, 17, 18, 8, 19, 20, 21, 22, 9, 23, 24, 25, 26, 27, 28, 10, 29, 30, 11, 31, 32, 33, 34, 35, 36, 12, 37, 38, 39, 40, 13, 41, 42, 14, 43, 44, 45, 46, 15, 47, 48, 49, 50, 51, 52, 16, 53, 54, 55, 56, 57, 58, 17, 59 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,3 COMMENTS All positive integers occur exactly twice: A095117 and A095116 give positions of first and second occurrences. LINKS Reinhard Zumkeller, Table of n, a(n) for n = 1..10000 EXAMPLE 1,(1,2),(2,3),4,(3,5),6,(4,7),8,9,10,(5,11),12, ... . PROG (Haskell) a165634 n = a165634_list !! (fromInteger n - 1) a165634_list = concatMap (\x ->    if a010051 x == 1 then [a049084 x, x] else [x]) [1..] -- Reinhard Zumkeller, Apr 17 2012 CROSSREFS Sequence in context: A026350 A205002 A290735 * A128282 A146985 A132993 Adjacent sequences:  A165631 A165632 A165633 * A165635 A165636 A165637 KEYWORD nonn AUTHOR Reinhard Zumkeller, Sep 23 2009 STATUS approved

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

Last modified May 15 05:01 EDT 2021. Contains 343909 sequences. (Running on oeis4.)