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.

A355851 The difference between the indices of the two most recent instances of a(n-1), not including a(n-1) itself, or 0 if not enough such instances exist.

Original entry on oeis.org

0, 0, 0, 1, 0, 1, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 1, 9, 0, 2, 2, 4, 0, 8, 0, 4, 0, 2, 1, 2, 7, 0, 2, 2, 3, 0, 5, 0, 4, 4, 13, 0, 2, 1, 12, 0, 4, 1, 15, 0, 4, 7, 0, 4, 4, 3, 0, 3, 21, 0, 4, 1, 4, 6, 0, 3, 2, 9, 0, 5, 0, 4, 2, 24, 0, 2, 6, 0, 4, 9, 50, 0, 3, 8, 0, 4, 7, 21, 0, 3, 17
Offset: 1

Views

Author

Eric Fox, Jul 19 2022

Keywords

Comments

This is similar to Van Eck's sequence: A181391.

Examples

			Say you have 0, 0, 0, 1, 0, 1, 0, 2, 0, 2, 0, 2, 2, ?
The previous term is a 2, and the distance between the pair of most recent 2s before that is 2, hence ? = 2.
		

Crossrefs

Cf. A181391.