OFFSET
1,1
COMMENTS
Number k such that both k-1 and k+1 are in A007774.
EXAMPLE
11 is sandwiched between 10 = 2*5 and 12 = 2^2*3. Both 10 and 12 have exactly two prime factors. Thus, 11 is in this sequence.
MATHEMATICA
Select[Range[1000], Length[FactorInteger[# + 1]] == 2 && Length[FactorInteger[# - 1]] == 2 &]
PROG
(Python)
from sympy import factorint
def isA007774(n): return len(factorint(n)) == 2
def ok(n): return isA007774(n-1) and isA007774(n+1)
print([k for k in range(200) if ok(k)]) # Michael S. Branicky, Sep 10 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Tanya Khovanova, Sep 10 2022
STATUS
approved