There seems to be some interaction in the string eval as this code does run.
cmpthese (-5,{ me => "mymatch('AAAAA',2,['AAAAA','ATAAA', 'ATCGA','ATCAA']);", jk => "amatch('AAAAA',['2'],('AAAAA','ATAAA', 'ATCGA','ATCAA'));" });
While Joost is wrong (or I misunderstood him) about not being able it give Benchmark a string. His approach is normally the better one.

Update: The problem is that you are evaling the following strings:

mymatch(AAAAA,2,@arr)
amatch(AAAAA,['2'],AAAAA ATAAA ATCGA ATCAA)
-- gam3
A picture is worth a thousand words, but takes 200K.

In reply to Re: Benchmarking String::Approx by gam3
in thread Benchmarking String::Approx by monkfan

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":