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.
%I A080343 #11 Aug 19 2016 04:33:38 %S A080343 0,0,0,0,1,0,0,1,0,0,0,1,1,0,0,0,1,1,0,0,0,0,1,1,1,0,0,0,0,1,1,1,0,0, %T A080343 0,0,0,1,1,1,1,0,0,0,0,0,1,1,1,1,0,0,0,0,0,0,1,1,1,1,1,0,0,0,0,0,0,1, %U A080343 1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0 %N A080343 a(n) = round(sqrt(2*n)) - floor(sqrt(2*n)). %H A080343 Chai Wah Wu, <a href="/A080343/b080343.txt">Table of n, a(n) for n = 0..10000</a> %F A080343 Runs are 0^1, 0^1, 0^2 1, 0^2 1, 0^3 1^2, 0^3 1^2, 0^4 1^3, 0^4 1^3, ... %F A080343 a(n) = 1 iff n >= 4 and n is in the interval [t_k + 1, ..., t_k + floor(k/2)] for some k >= 2, where t_k = k*(k+1)/2 is a triangular number. %F A080343 a(n) = A023969(2*n). - _Michel Marcus_, Aug 19 2016 %o A080343 (Python) %o A080343 from gmpy2 import isqrt_rem %o A080343 def A080343(n): %o A080343 i, j = isqrt_rem(2*n) %o A080343 return int(4*(j-i) >= 1) # _Chai Wah Wu_, Aug 16 2016 %Y A080343 Cf. A023969, A080352. %K A080343 nonn %O A080343 0,1 %A A080343 _N. J. A. Sloane_, Mar 20 2003