From: David Morton Date: 2008-01-04T06:28:21+09:00 Subject: Re: Why does this code not return what I expect it to? -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Jan 3, 2008, at 3:23 PM, Sam Phoneix wrote: > "This is a test".scan(/\w\w/) {|x| puts x} your regex mataches 2 letter word characters. "a" is only one. David Morton Maia Mailguard http://www.maiamailguard.com mortonda@dgrmm.net -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (Darwin) iD8DBQFHfVNzUy30ODPkzl0RAucoAJ45N5rkzbbuMGr3jHAiF1NAwfPLrgCfeYo0 pDib5SU+hWuIJfKirdd9G6s= =VpNa -----END PGP SIGNATURE-----