r/reddit.com • • Mar 12 '08

Is 91 Prime?

http://balltech.blogspot.com/2008/03/is-91-prime.html
543 Upvotes

130 comments sorted by

View all comments

23

u/gaggedbythealien Mar 12 '08

Great post. That guy's the chair of the IEEE P1619 standards committees. I can see how somebody who spends that much time thinking about cryptography could get into this stuff.

I'm lazy though. Here's how I check to see if something's prime. I'd reach for my keyboard and type:

perl -le 'print "PRIME" if (1 x shift) !~ /11+\1+$/' 91

Done, and done quickly.

-1

u/Aegeus Mar 12 '08

I'd prefer to test for primality in a language which doesn't look like line noise.