It looks to me as if $content =~ tr/ / / could be calculated once outside the loop, and be kept in a variable.
Still I find the number of blanks to be a rather dubious metric (what about all those other whitespace characters? Do two blanks in a row still make sense to count double?)
In reply to Re^2: Text::Context or alternatives?
by moritz
in thread Text::Context or alternatives?
by Dave Howorth
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |