|
|
A299977
|
|
Lexicographic first sequence of positive integers such that a(n) + a(n+1) has a digit 7, and no term occurs twice.
|
|
1
|
|
|
1, 6, 11, 16, 21, 26, 31, 36, 34, 3, 4, 13, 14, 23, 24, 33, 37, 10, 7, 20, 17, 30, 27, 40, 32, 5, 2, 15, 12, 25, 22, 35, 38, 9, 8, 19, 18, 29, 28, 39, 48, 49, 58, 59, 68, 69, 78, 79, 88, 82, 45, 42, 55, 52, 65, 62, 75, 72, 85, 86, 41, 46, 51, 56, 61, 66, 71, 76, 81, 89, 83, 44, 43, 54, 53, 64, 63, 74, 73, 84, 87, 50, 47, 60, 57, 70, 67, 80, 77, 90, 97
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
A permutation of the positive integers.
|
|
LINKS
|
|
|
PROG
|
(PARI) a(n, f=1, d=7, a=1, u=[a])={for(n=2, n, f&&if(f==1, print1(a", "), write(f, n-1, " "a)); for(k=u[1]+1, oo, setsearch(u, k)&&next; setsearch(Set(digits(a+k)), d)&&(a=k)&&break); u=setunion(u, [a]); u[2]==u[1]+1&&u=u[^1]); a}
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|