5.12 Summary ¶
print statement prints comma-separated expressions. Each
expression is separated by the value of
OFS and terminated by
the value of
OFMT provides the conversion format
for numeric values for the
printf statement provides finer-grained control over output,
with format-control letters for different data types and various flags
that modify the behavior of the format-control letters.
- Output from both
printf may be redirected to
files, pipes, and coprocesses.
gawk provides special file names for access to standard input,
output, and error, and for network communications.
close() to close open file, pipe, and coprocess redirections.
For coprocesses, it is possible to close only one direction of the
- Normally errors with
printf are fatal.
gawk lets you make output errors be nonfatal either for
all files or on a per-file basis. You must then check for errors
after every relevant output statement.