http://qs321.pair.com?node_id=84776


in reply to PGA Golf, Round 1 - Results

I disagree on #3's minimum score, as seen by my comments in my answer:
# 3 -- 23 chars # note: using $ instead of \z is *wrong* # note: using . without /s is *wrong* sub g3 { pop=~/^(.*?)\1+\z/s&&$1 }
For that matter, par is 22:
sub g3 { pop=~/^(.*?)\1+\z/s;$1 }


japhy -- Perl and Regex Hacker