Your First Program

To write your Perl programs, you need a utility called a text editor. A text editor is a program that allows you to enter plain text, without any formatting, into a file. Microsoft Windows Notepad and the DOS EDIT.EXE program are both sample text editors. For UNIX, vi, emacs, and pico are all text editors. At least one of them will be available on your system. Under the Mac, the MacPerl application contains a rudimentary text editor; to open a new program, select New under the File menu.

You should not use a word processor to type in your Perl programs. Word processors—such as Microsoft Word, Wordpad, WordPerfect, and so on—embed formatting codes inside documents when they're saved, even if the documents contain no special ...

Get Sams Teach Yourself Perl in 24 Hours 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.