%I #12 Sep 08 2022 08:44:53
%S 5,23,31,37,43,59,67,71,73,83,97,101,103,109,113,131,137,163,173,191,
%T 199,211,223,227,233,239,241,251,263,269,271,277,281,293,313,331,359,
%U 367,373,379,401,409,419,421,431
%N Primes p such that 42 is not a square mod p.
%H Vincenzo Librandi, <a href="/A038922/b038922.txt">Table of n, a(n) for n = 1..1000</a>
%t Select[Prime@Range[120], JacobiSymbol[42, #] == -1 &] (* _Vincenzo Librandi_, Sep 09 2012 *)
%o (PARI) select(n->!issquare(Mod(42,n)),primes(100)) \\ _Charles R Greathouse IV_, Sep 09 2012
%o (Magma) [p: p in PrimesUpTo(431) | not IsSquare(R! 42) where R:= ResidueClassRing(p)]; // _Vincenzo Librandi_, Sep 10 2012
%o (Magma) [p: p in PrimesInInterval(3,431) | JacobiSymbol(42,p) eq -1]; // _Bruno Berselli_, Sep 10 2012
%K nonn,easy
%O 1,1
%A _N. J. A. Sloane_.
%E Offset changed from 0 to 1 by _Vincenzo Librandi_, Sep 09 2012