Perl is a stable, cross platform programming language. It is used for mission critical projects in the public and private sectors and is widely used to program web applications of all needs.
Perl is dynamic programming language created by Larry Wall and first released in 1987. Perl borrows features from a variety of other languages including C, shell scripting (sh), AWK, sed and Lisp.Perl is based on the brace-delimited block style of AWK and C, and was widely adopted for its strengths in text processing and lack of the arbitrary limitations of many scripting languages at the time.
Features
The overall structure of Perl derives broadly from C. Perl is procedural in nature, with variables, expressions, assignment statements, brace-delimited code blocks, control structures, and subroutines.
Perl also takes features from shell programming. All variables are marked with leading sigils, which unambiguously identify the data type (scalar, array, hash, etc.) of the variable in context. Importantly, sigils allow variables to be interpolated directly into strings. Perl has many built-in functions which provide tools often used in shell programming (though many of these tools are implemented by programs external to the shell) like sorting, and calling on system facilities.
Design
The design of Perl can be understood as a response to three broad trends in the computer industry: falling hardware costs, rising labor costs, and improvements in compiler technology. Many earlier computer languages, such as Fortran and C, were designed to make efficient use of expensive computer hardware. In contrast, Perl is designed to make efficient use of expensive computer programmers.
Perl has many features that ease the programmer's task at the expense of greater CPU and memory requirements.
Applications
Perl has many and varied applications, compounded by the availability of many standard and third-party modules.
Perl has been used since the early days of the Web to write CGI scripts. It is known as one of "the three Ps" (along with Python and PHP), the most popular dynamic languages for writing Web applications (which now also include Ruby). It is also an integral component of the popular LAMP solution stack for web development. Large projects written in Perl include Slash, Bugzilla, TWiki and Movable Type. Many high-traffic websites, such as Amazon.com, LiveJournal.com, Ticketmaster.com and IMDb.com[14] use Perl extensively.
Implementation
Perl is implemented as a core interpreter, written in C, together with a large collection of modules, written in Perl and C. The source distribution is, as of 2005, 12 MB when packaged in a tar file and compressed. The interpreter is 150,000 lines of C code and compiles to a 1 MB executable on typical machine architectures. Alternatively, the interpreter can be compiled to a link library and embedded in other programs. There are nearly 500 modules in the distribution, comprising 200,000 lines of Perl and an additional 350,000 lines of C code. (Much of the C code in the modules consists of character encoding tables.)
Availability
Perl is free software, and is licensed under both the Artistic License and the GNU General Public License. Distributions are available for most operating systems. It is particularly prevalent on Unix and Unix-like systems, but it has been ported to most modern (and many obsolete) platforms. With only six reported exceptions, Perl can be compiled from source code on all Unix-like, POSIX-compliant or otherwise Unix-compatible platforms.[18] However, this is rarely necessary, as Perl is included in the default installation of many popular operating systems.
- Simple Program In Perl
print "Hello, world!\n"
This prints the string Hello, world! and a newline, symbolically expressed by an n character whose interpretation is altered by the preceding backslash.
- Sources For Documentation
- http://www.perl.com/
- http://www.perl.org/
- The Comprehensive Perl Archive Network, the gateway to all things Perl. The canonical location for Perl code and modules.
- Re-organized version of the "perl.1" man page for PERL version 4.
0 comments:
Post a Comment