On 11/2/06, Alan Young <[EMAIL PROTECTED]> wrote:
perl -ape
'$_="match\n";$i=1;while($i<@F){((abs($F[$i]-$F[$i-1])||@F)>[EMAIL
PROTECTED])&&($_="not
a $_")&&([EMAIL PROTECTED]);$i++}'
perl -ape '$_="match\n";$i=0;while(++$i<@F){((abs($F[$i]-$F[$i-1])||@F)>[EMAIL
PROTECTED])&&($_="not
a $_")&&last}'
I was tempted to take out the $i=0 (since ++undef is 1, right? :), but
it needs to be there to reset $i for each line, since it remembers its
value. Oh well.
Jacob Fugal
/*
PLUG: http://plug.org, #utah on irc.freenode.net
Unsubscribe: http://plug.org/mailman/options/plug
Don't fear the penguin.
*/