What would happen when using $1
, $2
... in the END
block, like:
awk '{print $3}END{print $1 $2}'
I found that $1
and $2
retain the values from the last record. Is this behaviour guaranteed by the standard or is it implementation-specific?
Checking the docs we see that it is implementation-specific: