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 A162318 #23 May 09 2021 04:56:24 %S A162318 5,6,7,10,13,20,22,27,32,37,45,46,50,51,58,61,62,68,73,74,76,82,91,92, %T A162318 106,115,117,123,124,146,152,153,157,164,166,170,174,178,187,188,193, %U A162318 206,212,226,235,236,245,261,262,267,272,274,277,278,284,291,313,325 %N A162318 A positive integer n is included if |d(n+1)-d(n)| = 2, where d(n) is the number of divisors of n. %H A162318 Robert Israel, <a href="/A162318/b162318.txt">Table of n, a(n) for n = 1..10000</a> %e A162318 68 is included because |d(69)-d(68)| = |4 - 6| = 2. [_Emeric Deutsch_, Jul 12 2009] %p A162318 with(numtheory): a := proc (n) if abs(tau(n+1)-tau(n)) = 2 then n else end if end proc; seq(a(n), n = 1 .. 350); # _Emeric Deutsch_, Jul 12 2009 %t A162318 Select[Range[500], Abs[DivisorSigma[0, # + 1] - DivisorSigma[0, #]] == 2 &] (* _Indranil Ghosh_, Mar 26 2017 *) %t A162318 Position[Abs[Differences[DivisorSigma[0,Range[350]]]],2]//Flatten (* _Harvey P. Dale_, Aug 14 2017 *) %o A162318 (PARI) isok(n) = abs(numdiv(n+1) - numdiv(n)) == 2; \\ _Michel Marcus_, Mar 26 2017 %o A162318 (Python) %o A162318 from sympy import divisor_count %o A162318 print([n for n in range(500) if abs(divisor_count(n + 1) - divisor_count(n)) == 2]) # _Indranil Ghosh_, Mar 26 2017 %K A162318 nonn %O A162318 1,1 %A A162318 _Leroy Quet_, Jul 01 2009 %E A162318 Extended by _Emeric Deutsch_, Jul 12 2009