I believe it was Larry who said, "You can write baby Perl and we won't laugh." I like that, and I've adopted it when working with new Perl programmers. We've all seen Perl as written by C programmers or as written by shell programmers. But some code I saw today really takes the cake. I think this is "Perl as written by a non-programmer"...
Here's the beginning, as the script's processing its args:
for ($i=0; $i < $size; $i++)
I won't post the part where the code reads the input file twice: once to count the lines, and again to pull it into an array...
I think the programmer just liked two-pass algorithms.