Saved Bookmarks
| 1. |
In The Text File, Some Lines Are Delimited By Colon And Some Are Delimited By Space. Write A Command To Print The Third Field Of Each Line.? |
|
Answer» AWK '{ if( $0 ~ /:/ ) { FS=":"; } else { FS =" "; } print $3 }' filename awk '{ if( $0 ~ /:/ ) { FS=":"; } else { FS =" "; } print $3 }' filename |
|