in reply to Re^2: Perl Vs Ruby
in thread Perl Vs Ruby

I don't know about Ruby, but I disagree that Perl is easy to learn. Perl has tons and tons of features, quirks, special cases, and its own lexicon of idioms.

Maybe I should have been more precise here. I want to say: It is easy to get quickly to a point where you can write useful programs. Of course by then you know only a small subset. For instance, I wrote my first useful Perl program after having read about 3-4 hours the introduction in the Camel book. Before that, I wrote programs in C++, C, Tcl, ksh, Pascal and some other languages. I found that with Perl I became productive quickly.

With Ruby, I found it somewhat faster to "go productive" and the language seems to me easier for beginners. I was teaching an absolute beginner Ruby as the first programming languages, and after maybe 10 hours in total, she was using it to write a 50+ line program which actually solved a concrete task (not a toy problem).

In this respect, both Perl and Ruby are easy to start with, I think. But any language with a lot of features take time to learn. Even languages with a simple syntax, like Java or Lisp, do. With those languages, the "experience" needed to master them is in understanding the libraries, respectively the functions.

May I ask you which languages you consider as simple to learn?

Ronald Fischer <>

Replies are listed 'Best First'.
by LanX (Cardinal) on Nov 26, 2008 at 13:49 UTC
    > May I ask you which languages you consider as simple to learn?

    IMHO, Javascript, very reduced but effective! (please note, I don't mean DOM!).

    Many people instantly can write JS Code.

    Unfortunately JS has some fundamental design flows, hindering to go further towards a all purpose language!

    1. "for in" operates on herited properties, without any possibility to add elements to prototypes which are flaged as not enumerable.
    2. prototypical inheritance is a very unusual concept (but simple)
    3. Packaging is not easy to realise.

    IMHO JS will replace VBS and Python as "built in scripting language" for applications.

    Cheers Rolf

    UPDATE: To avoid misunderstandings, JS is for sure no all-purpose language, but easy for beginners!

Re^4: Perl Vs Ruby
by JavaFan (Canon) on Nov 26, 2008 at 14:27 UTC
    May I ask you which languages you consider as simple to learn?
    I'm not sure if there's any general purpose language that's both useful (as in, allowing one to program in an efficient manner) and simple to learn.

    But to name one thing that makes a language easier to learn to program in than Perl is what I call "lack of distraction". Perl syntax is rich and full, but because of that, it offers a lot of distraction - it's hard to introduce a new concept without having to explain new pieces of syntax. For that reason, I claim that C, Java, Python, LISP, Pascal and Haskell are all easier to learn than Perl. Of course, if someone already has a lot of experience in procedurial languages (for instance C) it'll be easier to learn Perl than LISP or Haskell. But as a first language, the languages I mentioned are easier. You can reasonably quickly learn the syntax, and then when you teach more advance techniques, you no longer need to focus on syntax anymore.