Please excuse my ignorance, new to awk. Is there a way to modify this to only print from a line after the search string has been found
I have a file like this
##$D= (0-31)
0 2 3 4 5
And I would like to extract the value 2.
doing awk '/\$D=/ {c=2}c-->0 {print $2}' <file>
gives me:
(0-31)
2...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.