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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A318699 a(n) is the smallest nonnegative integer of opposite parity to n, not yet in the sequence, that shares a digit with a(n-1); a(0) = 1. 0
1, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 90, 9, 92, 21, 2, 23, 20, 25, 22, 27, 24, 29, 26, 61, 6, 63, 30, 3, 32, 31, 34, 33, 36, 35, 38, 37, 70, 7, 72, 47, 4, 41, 40, 43, 42, 45, 44, 49, 46, 65, 50, 5, 52, 51, 54, 53, 56, 55, 58, 57, 74, 67, 60, 69, 62, 121, 28, 81, 8, 83, 48, 85, 68, 87, 76, 71, 78, 73, 130, 39, 94, 59, 96, 79, 98, 89, 80, 101, 0, 103, 100, 91, 102, 105, 104, 107, 106, 109, 108 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

COMMENTS

Conjecture: this is a permutation of the nonnegative integers.

The one-digit integers appear in the following order: 1,9,2,3,7,4,6,5,8,0.

LINKS

Table of n, a(n) for n=0..99.

EXAMPLE

a(1) = 10 since 10 is the smallest even integer not yet in the sequence that shares the digit 1 with a(0) = 1; a(2) = 11 since 11 is the smallest odd integer not yet in the sequence that shares the digit 1 with a(1) = 10.

PROG

(Python)

cur = [1]

while len(cur) < 100:

....for x in range(100000):

........flag = False

........if x not in cur:#not currently used

............if x % 2 != cur[-1] % 2:#opposite parity

................j = str(x)

................k = str(cur[-1])

................for a in k:

....................if a in j:

........................cur.append(x)

........................flag = True

........................break

........if flag:

............break

print(cur)

# David Consiglio, Jr., Oct 04 2018

CROSSREFS

Cf. A107353, A297352, A297353.

Sequence in context: A102492 A169905 A076161 * A131835 A262390 A102236

Adjacent sequences:  A318696 A318697 A318698 * A318700 A318701 A318702

KEYWORD

nonn,base

AUTHOR

Enrique Navarrete, Aug 31 2018

EXTENSIONS

Corrected and extended by David Consiglio, Jr., Oct 04 2018

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 20 14:54 EST 2019. Contains 329337 sequences. (Running on oeis4.)