1 2 3 4 5 6 7 8 9
| grep 'handleShopBuy diff' run.log | wc -l
grep 'handleShopBuy diff' run.log | awk '$NF > 2000 && $NF <3000 {print $NF}'|wc -l
grep 'handleShopBuy diff' run.log |awk '{sum += $NF} END {printf "NR = %d,Average = %3.3f\n",NR,sum/NR}'
grep 'handleShopBuy diff' run.log |awk 'BEGIN{ max = 0} {if ($NF > max) max = $NF; fi} END{printf "Max = %.1f\n",max}'
grep 'handleShopBuy diff' run.log |awk 'BEGIN{min = 65535} {if ($NF < min) min = $NF;fi} END{printf "Min = %.1f\n",min}'
|