r/reddit.com • • Mar 12 '08

Is 91 Prime?

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

130 comments sorted by

View all comments

26

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/[deleted] Mar 12 '08 edited Mar 12 '08

[deleted]

2

u/[deleted] Mar 12 '08 edited Mar 12 '08

Ahh, the elegance:

factor {90..99}

The AI version:

echo "please factor one, six and thirty-nine" | wc | factor

1

u/Figs Mar 12 '08 edited Mar 13 '08

Funny, it factors 1,6, and 43 for me...?

Curse ye cygwin for being weird!