Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

What book would be valuable to someone self-taught?

by Anonymous Monk
on Oct 26, 2011 at 20:31 UTC ( #933990=perlquestion: print w/replies, xml ) Need Help??
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I have spent some time trying to learn Perl. While I find that I recognize and can recreate code with much of the syntax, (it's operators and most commonly used functions) I still am missing a small essential skill that would help me move forward: Learning how to actually program.

At first this wasn't so clear. I thought "Learn Perl" or even "Learn another language (at least through a few tutorials) to better understand Perl through comparison." Copying examples and running them etc. have been good but if asked to create a defined project from scratch I would be lost.

I took a look at some programming books from a list on StackOverflow to get ideas on something that will help fill the gap. It's a pretty big list and they all seem great but I honestly just want to pick up a book that will help get me unstuck sooner rather than later.

I reviewed a number of the books on the mentioned list and am considering purchasing one of the following:

  • Art of UNIX Programming
  • Code Complete
  • Pragmatic Programmer
  • Programming Pearls
If anyone has read some of these books I would greatly appreciate any feedback you may have.

Thank you

  • Comment on What book would be valuable to someone self-taught?

Replies are listed 'Best First'.
Re: What book would be valuable to someone self-taught?
by JavaFan (Canon) on Oct 26, 2011 at 21:45 UTC
    My recommendation would be "Advanced Programming in the UNIX environment". It doesn't contain any Perl, but it has done more for my understanding of Perl than any of the several dozens of O'Reilly books I own.

    Of your list, I've only read one, so I cannot compare.

      Indeed, any book by W. Richard Stevens is well worth reading. His writing style is as lucid as it gets.

      I'm a bit of the opinion that you can't really learn programming by books, though. That's not to say you shouldn't read books! You can pick up ideas, but to assimilate ideas you have to have some experience to base things on. You get that by programming, yeah? And you have your own way of thinking, so recommendations by others are....well, again, you can get ideas, things to try out, but ultimately you have to find out what does it for you, what makes things click for you personally. Whatever blows your hair back, as Will Hunting says.

      I originally "learned" FORTRAN from the FORTRAN 77 specification. No kidding, I think I printed it out. Of course, it's a terrible way to learn a language, and I forget it all. Or it's great, it depends on how you think. It certainly won't teach you how to do anything, but you can learn a lot of vocabulary and ideas, and if you don't know much about programming you might soak it up like a sponge. You'll still suck as a programmer, even if you sleep with it under your pillow. :)

      One rule of thumb I learned from somebody once was: pick up a book, flip to the middle, and if you don't understand it, it's not worth reading (yet). But yeah, you have to come up with your own rules of thumb.

        I'm a bit of the opinion that you can't really learn programming by books, though.
        Sure you can. It takes a bit more work that just flipping through the pages. Of course, you cannot learn programming for just reading books, but it sure beats firing up your editor and entering random characters in a file hoping it will compile (And where I wrote "books", feel free to substitute "manual pages").
      I have the original and the new one. This is not the right level for a beginner. This is great stuff when we talk about complex client-server and multi-process applications.

      You cannot go from "I want to ride bicycles" to "drive motorcycles in motocross competitive races" in a single step!

      I recommend again K&R for a study of how loops work. It is short, but the information content is dense. A lot is said in few words.

        The OP is considering books like "Art of UNIX Programming", "Pragmatic Programmer" and "Programming Pearls". He also declared he knows about the syntax and such - he can actually code. I think he's already way past the learning how to ride a bicycle. He seems to be more "great, I know how to ride a bicycle - now, how can I scale a mountain on one?".

        I certainly assume the OP knows how to write a loop.

      Thank you for the recommendation. I started reviewing samples from the book and it is pretty impressive but not overwhelming even at about 1,000 pages. I too have many of the 'Blue and White' books and really have only dog eared one or two.

Re: What book would be valuable to someone self-taught?
by bennierounder (Acolyte) on Oct 27, 2011 at 00:27 UTC

    I would recommend learning perl by Randal Schwartz and do as many exercises in the book as you can, then when you wanna learn more get the video by Randall Schwartz Learning Perl then do the exercises again. Read the book first!

    Then build an idea of a business model, using perl. i.e a website maybe that uses a database. Then look up the things you want to include by using modules and perl code.

    Then try and build another web based program that can make changes to the website via web interface. Then start doing reports. Set permissions for different users. The things you study will be the things you want to learn to improve your project.

    There are more advanced books you will need to read and refer to along the way. Inetermediate Perl, Programming Perl, Perl Monks and the main one Google. Doing Perl as a job is handy too.

    You also need to learn sql but that's easy and learning how to configure apache2 is a bitch.

    Skys the limit! That's all I know so far, I'm on the journey.

    It's probably the same route for any language really, I'm starting python next I think, possibly java (but I hear you need alot of time building, yet it's supposedly easy to maintain).

    Whatever route you choose, good luck

Re: What book would be valuable to someone self-taught?
by BrowserUk (Pope) on Oct 26, 2011 at 20:36 UTC

    Of your list: Pragmatic Programmer.

Re: What book would be valuable to someone self-taught?
by Marshall (Monsignor) on Oct 26, 2011 at 22:29 UTC
    I personally don't think that Perl is a good first language because it is huge with a lot of functions and for many things there can be multiple syntax's that work (I think for a beginner, this "many ways to do something" sometimes get in the way) - Perl borrows from many languages.

    The traditional way to start would be with a much "smaller" language like C. Although nowadays many schools favor learning an OO (object oriented) language like Java first.

    The fundamental issue is how to "think algorithmically" - how to break a complex problem down into steps that can be implemented in terms that the computer can understand. And then how to code each step. The "interfaces" between each section (step) of the program are very important.

    Programming is an art that is based upon science. The science part concerns things like how to sort things based upon the minimum number of comparisons. There are well known data structures (how to organize data) that allow us to access data efficiently.

    There are many folks on this forum who have spent most of their lives learning about software and how to write it.

    My question for you would be: what level of proficiency do you want to achieve? What kinds of programs do you want to write? What would they do?

    I would recommend that you register as a user (its free) and then you can send me or others messages amongst other benefits.

    Anyway, tell use what you want to use software to achieve? In terms of functionality that would be useful to you.

    You can get a lot of help here as long as the forum believes that you are trying and we aren't doing your class homework for you.

    As far as short books, I would recommend K&R (Kernighan and Ritchie) Programming in C. The main thing to understand are basic loop structures and the idea of a "data type", integer vs a floating point. This is a "classic". But I will admit that perhaps it is not the best place for you to start depending upon what you want to accomplish.

    I would recommend that you give us some guidance as to what you want to accomplish.

      Can't agree with you there. C is an awful language for a beginner. All that pointer management. 20-odd% of a C developers time (according to research quoted by Robert Glass) is spent debugging memory-address errors. Great practice for debugging the linux kernel. Not so great for web page scraping.
        I did not say that C is the "right" place for all beginners to start. I said: I will admit that [C] perhaps it is not the best place for you to start depending upon what you want to accomplish.

        This has a lot to do with how proficient you want to become and what kind of problems that you want to solve.

        Basic loop structures, data types, etc are very important. These are the basics. You won't write Perl or any programming language very well unless you understand these fundamentals. This is true in BASIC, JAVA, FORTRAN, C, Perl.

Re: What book would be valuable to someone self-taught?
by KevinZwack (Chaplain) on Oct 26, 2011 at 21:49 UTC
    I see a great many good books on the StackOverflow list. I think algorithms and data structures are the meat and potatoes or foundations of programming and would recommend reading up on those topics. There is a book by Aho, Ullman, & Hopcroft which is sort of a classic. I've read three of the four books on your short list, and I think they help somebody who is already well versed in the fundamentals of programming to be a better programmer. I can't really recommend them as a starting point, however.
Re: What book would be valuable to someone self-taught?
by williams554 (Sexton) on Oct 27, 2011 at 00:54 UTC

    There is some online stuff...

    You could google "MIT intro to computer science online" they start in Python. They have PDFs and class videos online.

    Standford also does this. They start programing in "Karel" It's a robot you run around and it starts with I think four instructions. One is you can only turn left. So, you make a subroutine to turn right with three turn lefts. etc.. They don't want the language to distract you from the concepts. They then move on to Python.

    google "Standford online introduction to computer science"

    Also, "Khan Academy" has a section on Python.

    Good Luck, Rob

    I cheated and got the answer.
    First I asked "what is the best programming language to learn?"
    And the answer is: c
    what is the best book to learn c?
    answer is: Rather than a book, try googling for C TUTORIAL.

    Let me put it this way, Mr. Amor. The 9000 series is the most reliable computer ever made. No 9000 computer has ever made a mistake or distorted information. We are all, by any practical definition of the words, foolproof and incapable of error.

Re: What book would be valuable to someone self-taught?
by ricDeez (Scribe) on Oct 27, 2011 at 03:16 UTC

    This is what worked for me:

    • Learning Perl (the 6th edition of this book has just come out and it is great!)
    • Intermediate Perl
    • Mastering Perl
    • Modern Perl

    It would also pay to get a subscription to the Perl journal (even though it hasn't been updated in a while, and work through all past papers).

    As someone else mentioned, it would also pay to practice as much as possible and get comfortable in whatever editor you use to code in. Try to work through all the exercises in Learning Perl...

    Good luck in your quest... Perl isn't the easiest programming language to learn but it is a very rewarding one...

Re: What book would be valuable to someone self-taught?
by johnny_carlos (Scribe) on Oct 26, 2011 at 23:21 UTC
    Of the books you mention, the only one I can comment on because I've read it is Code Complete. And I can say that it is a great read for people learning to program. Haven't read it in 10 years, but I've just ordered Code Complete 2 to refresh myself.
Re: What book would be valuable to someone self-taught?
by Anonymous Monk on Oct 27, 2011 at 07:14 UTC
    Personally I think far too much is made of paradigms and methodology. The principles of good s/w construction were set out early on by the likes of Steele,Brooks,Parnas, & Knuth, and have not changed.
    The books I use most are of course reference books - "Effective Perl", "Perl Cookbook" etc. But the books that have made me think about how to approach software are the ones that have some philosophical as well as practical content:
  • The Mythical Man Month
  • Structure & Interpretation Of Computer Programs
  • Higher Order Perl
  • Javascript - The Good Parts

  • But these days there is so much material on the net you don't need to worry about books so much. Some people worth looking up:
  • Doug Crockford
  • Paul Graham
  • Joel Sprolsky
  • Matthias Felleisen

  • In my opinion the most important things a beginning programmer should know are:
  • There so many ways to get things done. The computer won't care which one you use.
  • Human beings are hopeless at predicting the future so don't try and justify complex solutions in the name of maintainability.
  • There is no empirical evidence that OO leads to better software.

    2 nice quotes which I think sum up just why we shouldn't get too precious about languages, paradigms and (my all time least favourite word) methodologies:
    I am rarely happier than when spending entire day programming my computer to perform automatically a task that it would otherwise take me a good ten seconds to do by hand. Douglas Adams
    Plan to throw one away - you will anyway. Fred Brooks
      There is no empirical evidence that OO leads to better software.

      That does appear to be true. I don't know of any convincing argument to the contrary.

        There is no empirical evidence that OO leads to better software.
        That does appear to be true. I don't know of any convincing argument to the contrary.

        Maybe OOD leads to better software, because, it actually requires thinking about design :)

Re: What book would be valuable to someone self-taught?
by Anonymous Monk on Oct 27, 2011 at 02:08 UTC


    Whichever book/s you choose, read them near your computer. Try things out. Change bits of the code and see what happens.

    Read the books for guidance, but learn by doing.

    Well it worked for me.


Re: What book would be valuable to someone self-taught?
by rspishock (Monk) on Oct 27, 2011 at 11:21 UTC

    I started with James Lee's Beginning Perl Second Edition. I have taken several programming classes (Basic, C++, Java) and was never fully able to grasp programming. I understood a lot of the concepts, but I was never able to actually write any meaningful code. After getting half way through Beginning Perl, everything just clicked. I'm also casually flipping through Learning Perl and I have Intermediate Perl sitting at home, waiting to be read.

    My method of study was to read each chapter thoroughly, write out each of the examples in the chapter, do the exercises at the end of the chapter, and then play around with the code I just wrote to see how it would be affected.

    I'm still only a little over half way through the book, but I've been writing more advanced code (at least for me) to reinforce what I've read.

    For me, the best way to learn was to read enough to get the basic understanding of what the language can do, and then come up with a project to work on that's more interesting than the examples in the book. For example, I'm currently working on the fifth revision of a password script that generates various types of random passwords based on the user's criteria. The passwords are also verified to meet generally accepted security criteria; length, complexity, repetition of characters, etc. My next project is to create a program that will search pcap files for data that's stored in the reserved space of the header to signal possibly use of steganography.

    When it comes to buying a book, taking advice is helpful, but I've found it better to just hit up your local bookstore and flip through a couple of the books on the topic and see which one you like. Pick a book or two, go home and spend some time reading it and working through the examples, but then, start working on something a little more meaningful to you than just outputting text to a command line or a file. When you actually care about the project you're working on, you're less likely to lose interest in it. And when you get stuck on something, post it here, you'll get plenty of answers which will help you get passed the problem that you're having.

Re: What book would be valuable to someone self-taught?
by pobocks (Chaplain) on Oct 27, 2011 at 07:28 UTC

    I'd probably not get The Art of Unix Programming, if only because it's available online here:

    for(split(" ","tsuJ rehtonA lreP rekcaH")){print reverse . " "}print "\b.\n";
Re: What book would be valuable to someone self-taught? (Clarification)
by Anonymous Monk on Oct 27, 2011 at 14:27 UTC

    Thank you all for the suggestions. I apologize if I did not make this more clear in my question but I am not looking for recommendations on Perl books as I have more than I probably need. I am trying to move past the tinkerer who can cook from recipes to, while maybe not Iron Chef, being able to create my own meals with just a few ingredients and little instruction.

      I suggest that you register as a user on Monks. That will allow you to send me or other Monks messages amongst other benefits.

      Think about what kind of programming problems that you want to solve. Try to solve one. When you get into trouble, post your current effort here and ask for help.

      I'm sure that you will get a lot of help.

      Software programming is very much an art. It requires practice and study. Practice involves "learning by doing".

Re: What book would be valuable to someone self-taught?
by perl.j (Pilgrim) on Oct 27, 2011 at 19:03 UTC

    Learn a New Language

    That's the best advice I can give you. Perl is a great, powerful language, don't get me wrong there. But you don't have to be stuck with Perl forever. There are not many ways to take a step up from Perl, as it truly is extremely powerful. But taking a step down will only help you.

    You can learn C or C++ as they are great languages, but are pretty limited compared to Perl. Because Perl has most of the functions that C uses, this will help you when you use Perl, as I can almost guarantee you have not used everything Perl has to offer.

    You could also shift to another language that is comparable to Perl, such as Python. I have never used Python before, but I've heard it is extremely powerful and pretty cool (not as cool as Perl of course).

    As for the books...

    • Pragmatic Programmer
    • Programming Pearls

      Another option would be to learn a different language that tends to force you to think in different ways. I've mostly used Perl in procedural ways, because that was my background from assembly and BASIC and C, so lately I've been dabbling with Lisp/Scheme, to get more comfortable with functional programming and concepts like closures and first-class functions. You can do functional programming in Perl, and some recent books like Higher Order Perl get into that; but a language like Lisp practically demands it, and tutorials include it as par for the course. Getting out of my comfort zone helps me to stop thinking, "Yeah, but why not just do it the way I've always done it?" and immerse myself in this different way of solving problems. Then I can come back to Perl and apply what I've learned.

Re: What book would be valuable to someone self-taught?
by Posthumous (Scribe) on Oct 28, 2011 at 01:06 UTC

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://933990]
Approved by Corion
Front-paged by Corion
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (8)
As of 2017-01-16 20:08 GMT
Find Nodes?
    Voting Booth?
    Do you watch meteor showers?

    Results (151 votes). Check out past polls.