The polynomial f ( x ) = x 2 + 1 1 x + 4 7 is a prime number for 11 consecutive integers, x = 0 , 1 , … , 1 0 .
The polynomial g ( x ) = x 2 + a x + 2 2 3 is a prime number for 27 consecutive integers, x = 0 , 1 , … , 2 6 .
Find the constant a .
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Quick search using M a t h e m a t i c a
Select[Range@100,And@@PrimeQ@Table[223+#*g+g^2,{g,0,26}]&]
the above code returns 2 7
How do you know that the answer must be at most 100?
Log in to reply
Let me explain it to you for the third time.
step 1 You make a brute force program
step 2 You test it in a small range (in this case 100)
step 3 If you don't get any results, you search in bigger range (say 1000 or 1000000)
step 4 If the problem is too tough then brute force don't work and you have to do maths
step 5 I am just describing the way I got the right answer
step 6 Are you obsessed with my mathematica answers???
cause many people here are interested in one-liner code solutions
Log in to reply
Maybe there's a value of a larger than 100 that satisfies the given conditions as well?
Log in to reply
@Pi Han Goh
–
then the question is wrong and it should ask for the smallest integer.
Anyway many problems on this site are not well-stated (and if you know this it helps you getting the right answers)
Log in to reply
@Giorgos K. – How do you know that this question isn't wrong?
Many problems? From who? The staffs or from the community?
Log in to reply
@Pi Han Goh – Obviously the person that posted this question believes that there is only one solution. ask him. It is very natural that many of the posts are problematic and that's why the community should report and clarify. I think we must end this discussion here my friend
Problem Loading...
Note Loading...
Set Loading...
− 2 7 is also solution.