Regex to match odd numbers

David Cantrell david at cantrell.org.uk
Wed May 28 12:37:06 BST 2014


On Tue, May 27, 2014 at 04:42:40PM +0100, Alex Balhatchet wrote:

> Odd numbers end in [13579] so... m{5 [.] \d* [13579]}gmsx ... ?

Oh yeah, so embarrassingly obvious. The solution is to *remember that
version "numbers" aren't numbers, they're text*.

-- 
David Cantrell | London Perl Mongers Deputy Chief Heretic

Perl: the only language that makes Welsh look acceptable


More information about the london.pm mailing list