First PERL Program



Lets create a first.pl and type the following text

#!/usr/local/bin/perl
print “Hello Pratap\n”;

The first line tells the program where to pick the interpreter to execute the rest of the code

in the file.
The print command is a PERL in built function to print the text following by the print
word to the standard output.
Save the file and close. Allow executable permissions and then run the program. You
would see a nice text “Hello Pratap” printed on your screen.

No comments:

Post a Comment