News for hackers. Stuff that matters.
Re:Is This Prime? by lalaithion on Thursday July 15, 2021 @05:24PM (#27850321)
This reminds me of my favorite in-person magic trick to do.

First, memorize all the two-digit primes. 25 numbers isn't that hard to memorize.

Then, tell someone "Oh, I can instantly tell whether a number is prime or not. Give me a number, I'll tell you whether it's prime."

If they tell you a number between 1 and 100, use your memorized list. Otherwise, it's a game of cold reading; if they just generated a random string of many digits, there's a low chance that the number actually is prime. "21923847" is a keysmash, and it's almost certainly not prime, because the frequency of primes goes down as numbers get bigger. And most people will ask you a number, hear "no", and then go check the number's primality. Eventually, they'll look up a number in advance; that number is almost certainly prime.

Re:Is This Prime? by float4 on Thursday July 15, 2021 @05:43PM (#27850486)
And then one day, somebody asks you calmly: "what about 2^31-1"? Better memorise the small Mersenne exponents as well!

https://oeis.org/A000043

Re:Is This Prime? by aidenn0 on Thursday July 15, 2021 @07:30PM (#27851312)
Also, most composites are divisible by 2, 3 or 5, all of which are very easy to check (for 3 just sum up the digits and if the result is divisible by 3, the original number is divisible by 3). 49, 77, and 91 are the only composites under 100 that is not divisible by one of those 3 numbers, making memorizing 25 numbers not even necessary. 49 and 77 are obviously composite to me making 91 the only number I bothered memorizing.
Re:Is This Prime? by pkulak on Thursday July 15, 2021 @11:13PM (#27852709)
53?
Re:Is This Prime? by dhruvrrp on Thursday July 15, 2021 @11:16PM (#27852726)
53 is prime
Re:Is This Prime? by pkulak on Friday July 16, 2021 @11:10AM (#27857047)
Oh, shoot, brain fart. I was thinking OP was listing primes and forgot one. :D
Re:Is This Prime? by OriginalNebula on Friday July 16, 2021 @04:01AM (#27853949)
21923847?
Re:Is This Prime? by nxpnsv on Friday July 16, 2021 @04:23AM (#27854071)
Only 14 away from a prime though
Re:Is This Prime? by falseprofit on Friday July 16, 2021 @03:58AM (#27853934)
57?
Re:Is This Prime? by techbio on Friday July 16, 2021 @08:47AM (#27855666)
Re:Is This Prime? by sincerely on Friday July 16, 2021 @04:13AM (#27854018)
5+7=12 thus divisible by 3 and not prime
Re:Is This Prime? by techbio on Friday July 16, 2021 @04:16AM (#27854040)
Re:Is This Prime? by lordnacho on Friday July 16, 2021 @02:32AM (#27853547)
Somehow I've memorised 10243 in order to have a "big prime" that most people can't just determine. Note its the lowest 5 digits.
Re:Is This Prime? by ithinkso on Friday July 16, 2021 @05:17AM (#27854421)
I'm always using 1000003 and 1000000009 if I need a big prime in code. Million 3, billion 9 - very easy to remember
Re:Is This Prime? by techbio on Friday July 16, 2021 @04:18AM (#27854051)
I've now memorized 10247, the second-lowest over 5 digits. Everyone else get in line.
Re:Is This Prime? by the_arun on Thursday July 15, 2021 @06:22PM (#27850816)
After 8 attempts, I ran into "Game Over". Was just thinking about the satisfaction for the author of this site. There is just enormous fun in saying - Game Over - to another human :)
Re:Is This Prime? by maximus-decimus on Friday July 16, 2021 @09:25AM (#27855975)
That's a lot of effort just for tricking people into thinking you can tell if a number is prime.
Re:Is This Prime? by mjthompson on Friday July 16, 2021 @02:16AM (#27853474)
I hope the twin prime conjecture holds, since it would be pretty incredible to think that, despite what you said, there are infinitely many twin primes.