Skip to main content
1 of 3
ZaMoC
  • 24.9k
  • 2
  • 30
  • 81

#Mathematica, 31 bytes

P=PrimeQ;P@#&&(P[#+2]||P[#-2])&
ZaMoC
  • 24.9k
  • 2
  • 30
  • 81