Day 15. Working with Files and I/O

Throughout the first two weeks of this book, I introduced you to input and output (otherwise known as I/O) a little at a time. You've learned about standard input and output using <STDIN> and print, and about file input using the command line, the <> operator, and a while loop to automatically assign each line to the $_ variable.

In today's lesson, we'll expand on what you already know about input and output in greater detail, as well as touch more on script argument lists and getting data and options into your script. Today, we'll explore

  • All about file handles: creating them, reading input from them, writing output to them

  • Simple file tests for finding out information about a particular file

  • Working with script ...

Get Sams Teach Yourself Perl in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.