On 11/18/2010 05:39 PM, sc wrote:
# sum last word
{ total += $NF }
END { print total }
that sums the last word of each line (if it's numeric), how
can i feed it a range of lines and read the sum in after the
end? reading the help it appeared i could enter
:5,9r!awk -f ~/su
all--
if i have a simple awk script like
# sum last word
{ total += $NF }
END { print total }
that sums the last word of each line (if it's numeric), how
can i feed it a range of lines and read the sum in after the
end? reading the help it appeared i could enter
:5,9r!awk -f ~