Input/Output
Format Output
- A format is bound to an output stream using the select()
function
select( ( select(STDOUT), $^ = 'MyHeader', $~ = 'MyBody')[0] );
- Subsequent write() function calls output tabular data
while ( $employee = ) {
( $name, $age, $bonus, $date ) =
split( /\s+/, $employee );
write;
}