Re: Perl Programming was Introducing Interactive Perl

  • From: "Octavian Rasnita" <orasnita@xxxxxxxxx>
  • To: <programmingblind@xxxxxxxxxxxxx>
  • Date: Fri, 24 Oct 2008 05:54:35 +0300

Perl has many advantages, and of course, many disadvantages when comparing
it with other languages, so there isn't a middle road. You love it or hate
it. (I wasn't the one that said this for the first time, but I agree with it
a little.)

There is no language that's the best for making all kind of programs, so it
is the same with perl. In my opinion, perl is best for writing web apps,
system administration apps, and programs that need to parse text files,
extract relevant information, work with data which isn't extraordinary wel
formatted, and things like that.

It is also very good for creating simple apps with a graphical interface for
Windows, or programs which are portable to other systems, but as I said,
only simple apps.
For these apps, it requires very few lines of code.

For bigger and complicated desktop apps that use very many widgets on the
screen (like the interface of Eclipse or VS.net), or for apps that need to
use more threads, it is not the best at all, because it consumes too much
memory and is complicated to write.
This is because perl is process-oriented and not thread-oriented, and the
perl threads are not as light as the Windows threads... because perl is a
Linux language, not one borned under Windows.

Its main advantage is that it has the biggest archive of free libraries
(search.cpan.org) that you can download and install for free, or install
using the cpan command line, or install a precompiled version using
ActiveState's ppm command line program.

Without all those libraries, perl is pretty low level, but if using those
libraries perl is a higher level language than all other programming
languages.
You can find many libraries that do very complicated things, because they
use other libraries that use other libraries, but you will need to write
only 2 or 3 lines of code to do all that you want.

For creating web apps, I think that perl is still the best for many reasons,
including the fact that there are those tens of thousands of libraries
available.
A few months ago I wanted to start to learn a little PHP. I've started to
learn PHP for more times, but each time I was very disappointed to see how
hard is to do in PHP what I could do very easy in Perl, so each time I
abandoned.
This last time I searched more information about PHP frameworks, for not
needing to write a web app from zero, and I've tested a few of them. I was
impressed to see how many PHP frameworks there are, and I was sure I will
find a good MVC framework.

But unfortunately it wasn't the case. All of them have very few features and
require very much hand-coding which is not very nice.
Some of them don't have an ORM at all, some of them don't use a templating
system, almost all of them have a hard to use dispatcher mechanism, but even
the ORMs they have are very incomplete and hard to use for a little more
complex database queries.

I compared perl with PHP, because for web apps, after Perl I think the best
is PHP. It is much better and easy to use than DotNet or Java.
(And I can give examples about how to create a simple or complex web app in
very few steps, while doing the same thing in other languages is harder.)

Of course, there are some pretty good frameworks for other languages, like
Ruby on Rails for Ruby, but the problem is that Ruby or other languages
don't have so many libraries available that could be used in the web apps
they create, so after creating the apps, more manual working is needed.

Many people say that the perl programs are harder to maintain, because perl don't put so many restrictions like other languages as Java, DotNet, or python. Of course, if the programmers don't follow the same style of programming, it is hard to understand the code made by others if you don't know perl very well. And for this reason, the bigger teams of programmers prefer to use a language that force them all to use the same style of writing code.


Octavian

----- Original Message ----- From: "E.J. Zufelt" <everett@xxxxxxxxx>
To: <programmingblind@xxxxxxxxxxxxx>
Sent: Friday, October 24, 2008 12:46 AM
Subject: Perl Programming was Introducing Interactive Perl


Good evening,

I haven't touched Perl for over 10 years, but I notice a lot of dicussion
of Perl on this list.  Can someone explain the benefits of Perl
programming?

Thanks,
Everett


----- Original Message ----- From: "Jamal Mazrui" <empower@xxxxxxxxx>
To: <ProgrammingBlind@xxxxxxxxxxxxx>
Sent: Thursday, October 23, 2008 6:42 PM
Subject: Introducing Interactive Perl


I've been doing some Perl programming lately, and wished there was an
interactive environment like Python or Ruby.  There probably is one or
more by a 3rd party, but I have not found one in the ActiveState
distribution of Perl for Windows.  Since I had developed an Interactive
JScript environment using the .NET Framework, I thought I would try to
port the same ideas to a project with Perl and the native Win32 API.
Here
is my initial attempt.

Jamal



Now available at
http://EmpowermentZone.com/ipl.zip

Interactive Perl
Version 1.0
October 23, 2008
Copyright 2008 by Jamal Mazrui
LGPL license

Interactive Perl (IPL) is a console mode environment for testing and
evaluating code in the Perl language.  Run ipl.exe to start a session.
The file html.zip contains documentation on the modules bundled in the
executable.  Of course, there are other ways of finding relevant
documentation and examples.

I invite Perl programmers to contribute to this project.  Below is the
online help of this initial version:

Type a Perl statement or expression, followed by Enter.
A trailing semicolon (;) is not needed, but it may be used to seperate
multiple
statements on the same line.
Many modules are packaged in the executable,
so a 'use' statement is not needed:
Date::Calc, English, File::Basename, File::Slurp,
HTML::HeadParser, HTML::LinkExtor, HTML::Parser, HTML::Tagset,
HTML::TokeParser,
List::Util, LWP, LWP::Simple, LWP::UserAgent,
Scalar::Util, String::Util, Term::Screen::Win32, Text::Autoformat,
Text::Reform,
URI,
Win32, Win32::ActAcc, Win32::API, Win32::Clipboard, Win32::Console,
Win32::Exe,
Win32::FetchCommand, Win32::File, Win32::FileOp, Win32::FileTime,
Win32::GUI, Win32::GuiTest, Win32::Job, Win32::OLE, Win32::OLE::Const,
Win32::OL
E::Variant, Win32::Process, Win32::Service.
In addition, some built-in commands are available.
A command name is lower case, with a space before each argument,
and no quotes around it.
exit or quit = end this program
cls = clear the screen
eval FileName = execute a Perl script file
log FileName = log this session to a file
log off = stop logging
help = display this documentation

__________
View the list's information and change your settings at
//www.freelists.org/list/programmingblind



__________
View the list's information and change your settings at
//www.freelists.org/list/programmingblind


__________
View the list's information and change your settings at //www.freelists.org/list/programmingblind

Other related posts: