I’m hoping to print only the last word in every line of my file as in the below example. I tried using awk
‘print {$NF}’` but it doesn’t give the output I like as not all lines are of the same length.
My file contains lines like the below
ID_1 ABC;GHI;JKKK;KLLL
ID_2 JKL;YUI
ID_3 OPKJ
ID_4 uncK;oPTY
and I wish to have output as below
KLLL
YUI
OPKJ
oPTY
I would appreciate it very much if you’ve got any ideas on how to accomplish the above on bash