in reply to Should I learn Perl?

Perl, C, Assembler C++ Java in that order if you want an opinion. You can do 95% of stuff in Perl, 4% in C if you hit Perl's glass ceiling and 1% Assembler for raw speed. C++/Java probably have the widest commercial market if that is an issue (and you want to use your skills to get a 'real job') Some VB(S) helps if you want to Perl Win32 with full power. If you are doing CGI stuff some Javascript is useful for trivia like form validation, focus() and that sort of basic UI stuff. The javascript/Jscript stuff is a pain in the proverbial - FWIW I often just use a browser detect, an if/else and write the code twice.The Comprehensive Perl Archive Network - CPAN has library code of generally very high quality to do almost anything you might want to do. And that does mean ANYTHING.

The Camel Book (Programming Perl) is what you want for a reference. Learning Perl is among the better texts for learning the language. You will find all sort of useful links to these book and other relevant stuff at Outside Links

See the Tutorials section for some good free stuff that you don't have to have shipped (or pay for ;-). If you have done BASIC you will find Perl syntax similar and the ability to make stuff happen in a few short lines (especially with library code to start) somewhat addictive. You seem to looking towards CGI stuff so I recommend Ovids free Web Programming In Perl Tutorials as a start. Have a look at home nodes like merlyn and ybiC for more links to free quality info than you will be able to read this month - or next.

You will not find better support for any lang than you will find for Perl here and at comp.lang.perl.misc, Use Perl; perl.com to name a few others.

Sounds like you have come to the right place and are looking at the right lang. Perl is a power tool. You can do just about anything in it although you can probably do it with less memory/cycles (but with much more effort and time) in another lang. With the fat memory and fast processors these days the need to do it with ultimate efficiency (memory/cycles) is diminished. Just ask M$/intel ;-)

If you need it done yesterday you are far more likely to do it with Perl. BTW share your history to a degree. I started doing BASIC (and then assembler because you can't do much basic in 16KB of RAM) on a TRS-80.

Never say sorry for asking a question. There are no stupid questions. Only stupid answers. Hope to see you round hacking code and having fun....

cheers

tachyon

s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print

Replies are listed 'Best First'.
Re: Re: Should I learn Perl?
by skx (Parson) on Mar 09, 2003 at 12:15 UTC

     (I have a similar background, BASIC -> Z80 ASM -> C + C++ + Perl + Lisp)

     I normally suggest that people who aren't new to programming jump straight into Programming Perl, and skip Learning Perl.

     Whilst perl does hold a few suprizes, things like implicit arguments and special variables I think that if you're a programmer who's experienced in several languages, such as javascript, basic, etc you'd be better of with a real programming + reference book.

    Steve
    ---
    steve.org.uk

      I did Programming Perl first but it is fairly heavy going when you are starting. Indispensible certainly. The best ref without a doubt. I think it depends on how much of a masochist you are when it comes to starting with it.

      cheers

      tachyon

      s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print

Re: Re: Should I learn Perl?
by Anonymous Monk on Mar 10, 2003 at 06:16 UTC
    KK, Didn't realize that Assembler had actually survived... Nice to see that you can still take it down to that level. Also thought C had kinda been superceded by C++; whats the deal between those two? Is C++ just a more specific application of C, or is it similar to the whole JavaScript/Java thing; where the two have nothing in common but a name?


    Again, nice to see the same books being referenced again and again... good sign that I can trust them to get me into the thick of it.


    Kinda noticed that Perl and Basic had a lot in common... JavaScript, too for that matter... the way they handle the variables and loops and such all has a familiar ring to it. The operators still look a little strange to me, as is the use of (), [], {} for seperate things... Im more used to puting everything in basic parenthases and quotes...Ill adjust quickly, I think.


    I already checked out the tutorials, namely the one named 'The Basics', but it was already looking Greek to me, so I shouted out here. I figure I need a good book to be more familiar with the actual vocabulary first, then work on concepts; from what I've seen, the concepts will be the easy part for me. (the '#$amp{a$::bname&&()}' stuff is still looking a bit bizzarre tho! =)


    Support as I've seen for Perl would be quite welcome... nice to see that everyone is willing to chip in for each other. Looking forward to not always looking like a moron! Probably be very proud first time I point out the bug in one of your codes!


    Memory/cycles isn't really the problem for me... I like tight, error and bug free code that works well. I like even better that it does its job efficiently, and leaves everybody else scratching their heads wondering how I did it in only three lines. From what I've seen, Ill probably generally follow your suggestion of languages... but I'll probably put the assembler off till I got C, C++ and Java covered...


    I can understand the TSR-80 problem... I lived with a Commodor 64 for a full year before I got a disk drive! Try running that long on tape! took almost 45 minutes just for Logo to load (after I boosted the tape drive speed!) Coulda been worse, tho... had a buddy that was real proud the day he got his Radio Shack special; the CoCo 3 (in color! WOOT!).


    Me

      Here is my take on the languagues:

      Perl - Basic on steriods, instant gratification and debugging
           - Got a bad wrap in CGI circles because it was so easy to
           - do CGI stuff that lots of people did - BADLY
      C    - THE language that made programming what it is today
           - All the power of assembler in a (slightly) more user friendly package
      ASM  - Everything ends up here. To code C you need to have
           - a handle on the guts of the system anyway
      C++  - C extended to do OO better. Unnecessary for single programmer
           - as you can do it in C in half the code (procedural)
           - Forces you to be OO which is not needed for short stuff
           - It is way easier to do multi-programmer stuff OO with solid APIs
           - Yeah, yeah what starts little often suffers featuritis 
      Java - C++ with all the power toys taken away. Comiles to bytecode not ASM
           - Supposed to be portable but MS got involved ;-)
           - speed not that great due to partial compilation
           - TRENDY in management circles.
      

      Here is a nice one liner for you:

      perl -pi.bak -e 's/something/otherthing/g' <FILE LIST>

      That particular snippet does a search and replace on a list of files writing a backup to filename.bak in the process. Handy and 100s of times faster than doing the same in a Windows based editor.

      cheers

      tachyon

      s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print

        Corrections about Java:

        Comiles to bytecode not ASM

        FUD. There are native compilers. Java is widespread and has tonnes of compilers, including many native ones. You can compile it to (almost) anything you want.

        Supposed to be portable but MS got involved

        FUD. Microsoft's more involved in Perl.

        speed not that great due to partial compilation

        Big can of worms here, so I'll be vague. It's not as fast as well-written c or even c++ but it is slightly faster than Perl. Most people will agree with that definition but how much faster depends on what your doing and how you're doing it.

        TRENDY in management circles.

        Once again, FUD. This is implying that it doesn't stand on it's own technically. The poster wanted a technical review, this is a cheap shot.

        For the record, THIS IS A lc(PERL) SITE! Do not ask for comparisons here, they'll be biased as hell. Would you go to a christian website and ask what the best religion is? Same deal, only it's worse with programming languages. Forget everything you've heard here. Study them all, learn on your own.