1 / 15

PERL

PERL. Prepared by :- ROCKS. Introduction. The full name of PERL is Practical extraction and report language. It is similar to shell script and lot easier & powerful language. Perl is free to download from the GNU website so it is very easily accessible.

mick
Download Presentation

PERL

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. PERL Prepared by :- ROCKS

  2. Introduction The full name of PERL is Practical extraction and report language. It is similar to shell script and lot easier & powerful language. Perl is free to download from the GNU website so it is very easily accessible. Perl is also available for MS-DOS,WIN-NT and Macintosh. Perl has many features borrowed from other programming languages.

  3. Cont… The Perl system uses an interpreter, called “perl”. Usually Perl and perl are considered to be the same thing for practical purposes.

  4. Versions of Perl The current versions of Perl are all in the 5.X and 6.X series (6.X was released in 2001). If you have an older version of Perl (such as Perl 4.X), you should upgrade it as many changes were made between releases. In many Operating System Maybe Perl is already installed. Many operating systems such as Linux and UNIX but also Windows NT Resource Kit come with Perl installed.

  5. Cont… You can easily check whether Perl is loaded on your system by opening a console or terminal window and issuing the command: perl –v If you get a version number, Perl is installed. If you get an error message about command not found (or something similar), Perl is not installed.

  6. Where to download? Perl is available free of charge from many public sites. There are several releases of Perl available for different operating systems, so make sure you get a current release. For Linux or UNIX systems, visit perl.com for the latest releases. For Windows systems, you can compile the Perl source code yourself (a hassle) or download a preconfigured Windows release at activestate.com. For Macintosh, visit macperl.com for MacPerl.

  7. What you need in Perl? When you have installed Perl on your system, all you need to use the language is a text editor that can save ASCII files. All Perl scripts are written and saved in ASCII characters.

  8. Comments in Perl All comments in Perl are written starting with a # sign. Anything after the # sign through to the end of the line is ignored by the interpreter. Comments can be placed anywhere on the line, but commands cannot follow a comment on the same line. Multiline comments should have a # symbol as the first character on every line.

  9. Semicolons All valid Perl command lines end in semicolons. Without a semicolon, Perl continues to read onto the next line and doesn’t assume a carriage-return is the end of a statement. Perl uses semicolons in the same way as C,C++,and Java.

  10. Whitespace Whitespace is ignored by the Perl intepreter. You can use whitespace (spaces and tabs) anywhere in your programs to make them more readable. You should use whitespace to help format your scripts to show loops, logic layout, and continuation of statements.

  11. Operators in Perl • Standard Operators :- • + = Addition • - = Substraction • * = Multiplication • / = Division • % = Modulus • ** = Exponent

  12. Cont… • Comparison Operators :- • > = Greater than • < = Less than • >= = Greater or equal • <= = Less or equal • == = Equal to • != = Not equal to

  13. Cont… • String Operators :- • eq= Equal to • ne = Not equal to • gt= Greater than • lt= Less than • ge= Greater or equal • le = Less or equal

  14. Cont… • Boolean Operators :- • && = AND • || = OR

More Related