Hi,
I have a file like
abc bcdcde def
efg fgh
I want awk to read it and print
abc bcd cde def
efg fgh
i.e. substitute \ with " "
Can anyone help me here?
I tried
awk '{if ($NF=="\\" {$NF= " ";printf("%s",$0);} else {print}}' file
but it is horribly wrong.
Cheers,
Pravin.
I have a file like
abc bcdcde def
efg fgh
I want awk to read it and print
abc bcd cde def
efg fgh
i.e. substitute \ with " "
Can anyone help me here?
I tried
awk '{if ($NF=="\\" {$NF= " ";printf("%s",$0);} else {print}}' file
but it is horribly wrong.
Cheers,
Pravin.