Highest Columns Number Records Issue
I have a test.txt file with contents as follows:
1:2:3
123:5
34589:5:0
34567:8:7
781:9:09
Could you please help me getting the following output from that test.txt file?
345895:0
345678:7
7819:09
Explanation: below line contains the highest number column i,g. 3 and removed :
345895:0
345678:7
7819:09
awk 'BEGIN{FS=OFS=":"} NR>=3 { print $1,$3 }' yourfile?1:2:3has 3 columns too, so shouldn't12:3appear in the output as well?