learning perl- m01 - overview
DESCRIPTION
Beginners guide to Perl languageTRANSCRIPT
Copyright © Amstar Technologies 1
PPractical ractical EExtraction & xtraction & RReport eport LLanguageanguage
By: B.T.R NaiduB.T.R Naidu
Email: [email protected]
Copyright © Amstar Technologies
Copyright © Amstar Technologies 2
PERL
Overview
Copyright © Amstar Technologies 3
Perl OverviewWhat is Perl?
Perl stands for Practical Extraction and Report Language
Created by Larry Wall"Perl is designed to make the easy jobs easy, without
making the difficult jobs impossible." -- Larry Wall
Copyright © Amstar Technologies 4
What is Perl?Perl is a text and file-manipulation language, originally intended to scan large amounts of text, process it, and produce nicely formatted reports from that data.
Perl is concise and allows you to create very quick and easy solutions.
Highly portable and readily available on most Unix boxes.
Copyright © Amstar Technologies 5
Usage of PERLPerl evolved hand-and-glove with the Internet, and gained rapid popularity in its early days as a language for writing quick utility scripts.
It also gained popularity as a language for writing server-side CGI scripts for web servers.
Release 5 took Perl to a new level by introducing object-oriented programming features.
Version 5.005 introduced initial support for threaded programming
In the future is Perl 6, a complete and fully object-oriented re-implementation of Perl from the ground up.
Copyright © Amstar Technologies 6
HistoryLarry Wall, a systems programmer, developed Perl in 1986.He conceived it, after he felt the necessity for a good file manipulation and report generation tool.
It is an evolving language, continuously being updated to support new features.Despite this, it is still an easy language to learn.
Copyright © Amstar Technologies 7
Perl’s AdvantagesPerl has Advanced Language FeaturesEasy manipulation of processes, files, and strings Very portable Interpreted Higher level constructs than shell scripts More functionality than awk/sedRegular expression enhancements.It is available on most server platforms like Unix, Ms-Dos, Windows-NT, Windows 95, OS/2, Macintosh etc, for free.Perl has no limitations for line length or array size unlike C or other languages.Subroutines in Perl can have recursion to any number of levels.
Copyright © Amstar Technologies 8
Perl's DisadvantagesSince Perl is an interpreter it will not be as fast as its complier counterparts like C, C++ etc.
Perl is a developing language. So applications that rely on certain features of a particular version have to adapt to the feature changes.
Perl is not a suitable language for distributing applications that include trade secrets or for keeping your programming technique as a secret.
Perl does not impose good programming practice, so it is also easy to write badly constructed and hard-to-read code through sloppy programming.
Copyright © Amstar Technologies 9
Major features of Perl5Perl 5 is the latest version in an ongoing evolution of the Perl language.
The major new features of Perl version 5: (1) Multi-threading support (2) Integration with the Perl Compiler (3) Integration with Win32 (4) Fancier regexps
Copyright © Amstar Technologies 10
SummeryUses
Shell scriptsCGI, web engines
Good atText processingSmall/Medium sized projectsQuick solutionsPortability (to a certain degree)
Bad atEfficient large scale computationNeat code!
Copyright © Amstar Technologies 11