How to print last word in all lines irrespective of the length of each line?
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.