http://qs1969.pair.com?node_id=588110


in reply to Re^2: Stumped by regex
in thread Stumped by regex

yup, dumb mistake by me. Also though, I assumed there was a first name here too. So the above regex allows an additional space that it shouldn't. You're probably okay with just the following...
$name =~ m/^[a-z]+\s?[a-z]+$/i
...although this does force a minimum length of 2.

Having said this, if I'd seen JediWizard's reply, I wouldn't have posted mine. I think he nailed it first time (++).

---
my name's not Keith, and I'm not reasonable.