Question: a) Let P(n) = n +n +41. Write a computer program (in Java, Matlab or Python) which finds the smallest positive counterexample for the

a) Let P(n) = n +n +41. Write a computer program (in Java, Matlab or Python) which finds the smallest

a) Let P(n) = n +n +41. Write a computer program (in Java, Matlab or Python) which finds the smallest positive counterexample for the statement: "If n is a positive integer then P(n) is a prime number". b) Similar to a) find the smallest counterexample for the polynomial: g(x) = x-79x+1601.

Step by Step Solution

3.37 Rating (156 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Python import sympy def isprimenum if num 2 return False return sympyisprimenum def findsm... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!