read while read -aa do $[++a[2]] echo ${a[@]} done