for i in invALL.06* do grep -c '^Invoice Total' $i | read count echo "$i has $count Invoice Totals" done