Print out the fields, columns, or with 'Key words'

Contents of marks.txt:

1) Amit Physics 80

2) Rahul Maths 90

3) Shyam Biology 87

4) Kedar English 85

5) Hari History 89

https://www.tutorialspoint.com/awk/awk_basic_examples.htm

columns or fields

$ awk '/Hari/ {print $0}' marks.txt

        5) Hari History 89

你可能感兴趣的:(Print out the fields, columns, or with 'Key words')