Learn how to program

Too arcane syntax, too many special cases, bad handling of error
conditions, no built in parameter passing, etc.

It isn't that's impossible to read Perl - I find Perl reasonably easy
to read - but there's a lot of gotchas in it, and I wouldn't want them
on a beginner. There are, to my mind, only four things that might
have redemptive value in using Perl as beginner's language:
- Sigils might be useful to make the beginner remember the differences
between types
- The "softness" of string/number typing in perl (they're
automatically converted to each other depending on context) might be
easier for a beginner to start with ("It's a number already, why do I
have to call .to_i ?)
- The language is well enough known that it might be easier to find a
friend that use it to help out than in more unusual languages
- The language is full enough of traps that the new programmer may
learn "BE ALERT! TRUST NO ONE! THE LANGUAGE IS YOUR ENEMY AND MUST
BE BEATEN INTO SUBMISSION!"

Of course, I happen to like code, and I think you can end up being
fairly friendly with Perl after a short while - say, ten years of Perl
experience - so it's not a total loss...

If you've got other redeeming features of Perl for beginners, I'm
eager to hear them - if somebody can convince me I'm wrong, I've
learned something, so I'm always in favour :slight_smile:

Eivind.

···

On Feb 1, 2008 7:09 AM, Chad Perrin <perrin@apotheon.com> wrote:

Is this another example of the common (mis)conception that Perl is a
"write-only" language? It's not, and in fact it's an excellent language
for learning to program. It just may not be the best for learning OOP,
in particular.

Perl is a horrible language as far as aesthetics are concerned.

The expressions you want to do are riddled with snoopy swearing
characters.
I would never recommend it as a learning language.

Ruby is a lot better, however ruby in TOTAL is actually rather complex.

If you like CSS, html etc... you can start learning PHP, because despite
being a horrible language as far as design is concerned, PHP itself is
rather easy.

I dont think C, Java etc... fall into this language anyway because they
dont really have the ease of dynamic programming at all.

That being said though I think a ruby programmer should couple ruby with
a language like C++ C Java, not only because of speed, but also i.e. in
case of C to extend ruby. (I dont really use ruby for work, I use it for
fun and every task I need to do here)

···

--
Posted via http://www.ruby-forum.com/.

Learning Perl, by Randal Schwartz, is one of the all-time best books for
learning a programming language with very little familiarity with
programming at all. Something like its approach with the addition of a
teacher would make for an excellent instructional course for people who
essentially have *no* familiarity with programming.

PHP gets a lot of mileage out of how easy it is to pick up from scratch,
and do simple work with only minimal exposure. Perl has all the benefits
of PHP in this regard, with the exception of PHP's ubiquity for
markup-embedded coding on shared hosting accounts. What Perl *doesn't*
have is its brain-damaging limitations and design characteristics.

Ruby, I think, is the best language I've ever met for teaching object
oriented programming. I don't think it's quite as easily grasped for
someone who has never met a programming language before as Perl, without
additional guidance, though. Part of the reason for that is also the
reason Ruby's so good for teaching OOP (and Perl's so damned ugly for
OOP).

I think both Perl and Ruby are among the best languages I've ever
encountered for teaching programming -- with each being stronger in some
niches than the other. The same goes for UCBLogo as well.

Does that make sense?

···

On Sun, Feb 03, 2008 at 10:32:22PM +0900, Eivind Eklund wrote:

On Feb 1, 2008 7:10 PM, Chad Perrin <perrin@apotheon.com> wrote:
> > Ruby and Python are pretty decent choices, I think.
>
> To the list of high-level dynamic languages for teaching programming, I'd
> add Logo (specifically UCBLogo), Perl, and probably DrScheme.

Why Perl? I know Perl fairly well, unfortunately having done most of
my programming in it over the last 12 years, but I don't see why it
would be appropriate for teaching. I'd think all the weird
irregularities would get in the way, but if you actually have
experience with it, I'd like to hear why I'm wrong (if I'm wrong).

--
CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ]
McCloctnick the Lucid: "The first rule of magic is simple. Don't waste your
time waving your hands and hopping when a rock or a club will do."

The "irregularities" usually only happen when you are doing more
complicated Perl. For a starter language there is no reason to do that
and Perl is a good choice there. It has libraries for almost any
aspect of programming you would want to do. I find it personally "fun"
to program in myself and is a good first language for a hobbyist. I
don't discount Ruby as a started language either.

Robert

···

On Feb 3, 8:32 am, Eivind Eklund <eekl...@gmail.com> wrote:

On Feb 1, 2008 7:10 PM, Chad Perrin <per...@apotheon.com> wrote:

> > Ruby and Python are pretty decent choices, I think.

> To the list of high-level dynamic languages for teaching programming, I'd
> add Logo (specifically UCBLogo), Perl, and probably DrScheme.

Why Perl? I know Perl fairly well, unfortunately having done most of
my programming in it over the last 12 years, but I don't see why it
would be appropriate for teaching. I'd think all the weird
irregularities would get in the way, but if you actually have
experience with it, I'd like to hear why I'm wrong (if I'm wrong).

Eivind.

Thanks for the answers. I decided by Ruby.

What is the best book Ruby for someone who does not have experience in
programming?

.Learn To Program
.Why's (Poignant) Guide to Ruby
.Humble Little Ruby Book

Thanks.

···

--
Posted via http://www.ruby-forum.com/.

Perl is a horrible language as far as aesthetics are concerned.

The expressions you want to do are riddled with snoopy swearing
characters.
I would never recommend it as a learning language.

Paul Graham: "Real ugliness is not harsh-looking syntax, but having to
build programs out of the wrong concepts."

I think the attitude you've shown is indicative of a very superficial
view of programming language design -- not of problems with a programming
language.

Much as I loathe Python, personally, I still might recommend it as a
learning language. That's because I realize that my personal preferences
do not, in and of themselves, amount to a definitive judgment of the
worth of the language for teaching programming. Perhaps you could learn
something from that example.

Ruby is a lot better, however ruby in TOTAL is actually rather complex.

If you like CSS, html etc... you can start learning PHP, because despite
being a horrible language as far as design is concerned, PHP itself is
rather easy.

Holy cow. PHP is the new BASIC -- a great way to inflict permanent brain
damage on yourself by learning it first. It's a rare programmer who
starts out with PHP and fully recovers from the experience. Usually, the
path to full recovery involves lengthy therapy with Perl, in fact -- the
language most familiar to PHP users without its inherently brain damaging
characteristics.

I dont think C, Java etc... fall into this language anyway because they
dont really have the ease of dynamic programming at all.

Actually, C could be very useful as a first-time learning language. That
depends to a significant degree upon the student (and the teacher, even
if that teacher is a book), however. Most students should start with a
higher-level language, probably dynamically typed, though OCaml is an
interesting exception to that general guideline about dynamic typing. In
any case, C can be valuable for its relative semantic closeness to the
hardware.

···

On Sun, Feb 03, 2008 at 10:42:08PM +0900, Marc Heiler wrote:

--
CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ]
Larry Wall: "A script is what you give the actors. A program is what you
give the audience."

I agree with those points.

Robert

···

On Feb 4, 5:04 am, Chad Perrin <per...@apotheon.com> wrote:

On Sun, Feb 03, 2008 at 10:32:22PM +0900, Eivind Eklund wrote:
> On Feb 1, 2008 7:10 PM, Chad Perrin <per...@apotheon.com> wrote:
> > > Ruby and Python are pretty decent choices, I think.

> > To the list of high-level dynamic languages for teaching programming, I'd
> > add Logo (specifically UCBLogo), Perl, and probably DrScheme.

> Why Perl? I know Perl fairly well, unfortunately having done most of
> my programming in it over the last 12 years, but I don't see why it
> would be appropriate for teaching. I'd think all the weird
> irregularities would get in the way, but if you actually have
> experience with it, I'd like to hear why I'm wrong (if I'm wrong).

Learning Perl, by Randal Schwartz, is one of the all-time best books for
learning a programming language with very little familiarity with
programming at all. Something like its approach with the addition of a
teacher would make for an excellent instructional course for people who
essentially have *no* familiarity with programming.

PHP gets a lot of mileage out of how easy it is to pick up from scratch,
and do simple work with only minimal exposure. Perl has all the benefits
of PHP in this regard, with the exception of PHP's ubiquity for
markup-embedded coding on shared hosting accounts. What Perl *doesn't*
have is its brain-damaging limitations and design characteristics.

Ruby, I think, is the best language I've ever met for teaching object
oriented programming. I don't think it's quite as easily grasped for
someone who has never met a programming language before as Perl, without
additional guidance, though. Part of the reason for that is also the
reason Ruby's so good for teaching OOP (and Perl's so damned ugly for
OOP).

I think both Perl and Ruby are among the best languages I've ever
encountered for teaching programming -- with each being stronger in some
niches than the other. The same goes for UCBLogo as well.

Does that make sense?

Having just finished reading it, I think "Learn to program" is excellent,
very easy to read.

Why's is an amazing way of learning without realizing you are.

I think if you flip between both then it works very well.

···

On Feb 3, 2008 12:18 PM, Regnum@argentina.com Regnum@argentina.com < regnum@argentina.com> wrote:

Thanks for the answers. I decided by Ruby.

What is the best book Ruby for someone who does not have experience in
programming?

.Learn To Program
.Why's (Poignant) Guide to Ruby
.Humble Little Ruby Book

Thanks.
--
Posted via http://www.ruby-forum.com/\.

I agree with Ashley Wharton, re: the Poignant Guide and Learn to Program.

I found the Humble Little Ruby Book in need of some editing, frankly.
Both of the others truly impressed me, though.

···

On Mon, Feb 04, 2008 at 02:18:42AM +0900, Regnum@argentina.com Regnum@argentina.com wrote:

Thanks for the answers. I decided by Ruby.

What is the best book Ruby for someone who does not have experience in
programming?

.Learn To Program
.Why's (Poignant) Guide to Ruby
.Humble Little Ruby Book

--
CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ]
Kent Beck: "I always knew that one day Smalltalk would replace Java. I
just didn't know it would be called Ruby."

Interesting.

I worked heavily with a student who started with Learn to Program and I found myself needing to supplement the book a lot, just to get them to the point where they had a comfortable understanding. The file IO chapter in particular really doesn't seem to get the job done in that book.

I think everyone has their favorites.

James Edward Gray II

···

On Feb 4, 2008, at 4:23 AM, Chad Perrin wrote:

I agree with Ashley Wharton, re: the Poignant Guide and Learn to Program.

I found the Humble Little Ruby Book in need of some editing, frankly.
Both of the others truly impressed me, though.