cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A289286 Starting with a(1) = 1, a(n) = smallest nonnegative integer not yet in the sequence such that the last digit of a(n-1) plus the first digit of a(n) is equal to 8. The digit 0 is not allowed.

This page as a plain text file.
%I A289286 #9 Jul 24 2017 12:54:07
%S A289286 1,7,11,71,72,6,2,61,73,5,3,51,74,4,41,75,31,76,21,77,12,62,63,52,64,
%T A289286 42,65,32,66,22,67,13,53,54,43,55,33,56,23,57,14,44,45,34,46,24,47,15,
%U A289286 35,36,25,37,16,26,27,17,18
%N A289286 Starting with a(1) = 1, a(n) = smallest nonnegative integer not yet in the sequence such that the last digit of a(n-1) plus the first digit of a(n) is equal to 8. The digit 0 is not allowed.
%C A289286 The number of terms of this finite sequence is the eighth central polygonal number, n = 57.
%t A289286 Module[{a = {1}, k, d = 8}, TimeConstrained[Do[k = 2; While[Or[MemberQ[a, k], MemberQ[IntegerDigits@ k, 0], # != d] &[Mod[a[[n - 1]], 10] + First@ IntegerDigits@ k], k++]; AppendTo[a, k], {n, 2, 100}], 2]; a] (* _Michael De Vlieger_, Jul 14 2017 *)
%Y A289286 Cf. A002061, A289283, A289284, A289285.
%K A289286 nonn,base,fini,full
%O A289286 1,2
%A A289286 _Enrique Navarrete_, Jul 01 2017