Monday, April 25, 2011

A regular expression to check for prime numbers

In ruby:
http://www.noulakaz.net/weblog/2007/03/18/a-regular-expression-to-check-for-prime-numbers/

and the original, in perl:
http://montreal.pm.org/tech/neil_kandalgaonkar.shtml

I cringe a bit when I think about performance... but hey - it's cool!

No comments:

Post a Comment