in reply to Perl as one's first programming language
There are some really great replies here...in fact, IMHO they are all great and very thought-provoking.
They all made me harken back to my first programming experience...during the summer of my junior year in High School learning to program in Fortran on a batch system where we had to learn to use a punch-card machine and had to wait 3 days for our submitted jobs to get turned back to us.
I graduated to Basic when I went to Dartmouth for undergraduate study and was taught by John Kemeny who had just become dean of the college but still taught introduction to programming. It really is what turned me towards programming...not because it was a great language, but because it was easy to learn and...more importantly...I could run it on a time-shared system from a teletypewriter terminal instead of on punched cards and get almost instant feedback on typographical errors, structural errors in the logic, and the actual results of the program's excution.
But looking back on the experience, I realized that the single most important thing about learning to program was learning how to think about problems...about how to decompose the problem, how to see the flow of the solution and how to translate that into very precise actions. The computer alwasy did exactly what I told it...when something didn't turn out right, it was because I didn't correctly tell the computer how to accomplish the task.
Irrespective of whether Basic was a good or useful language...it was simple enough that I could focus on the problem rather than get all hung up on complicated or confusing syntax, or on the frustrating construction of things like FORMAT statements in Fortran. I could focus on the critical thinking, on structuring the problem, on learning to program.
Looking back on my first programming language...Fortran...I realize that it, too, started to get me there...but it took too much effort to get through the technicalities of 'format' statements, of making sure that everything started in column 7...except certain directives and, of course, the ever popular format numbering and continuation lines...that I lost the "forest for the trees". The syntax and language demands were too distracting (especially when we were also learning how to use the punch-card machine and waiting 3 days to get our job back only to find out that I'd hit the f-key rather than the d-key in a do-loop so that my fo-loop didn't compile...argh!).
As a first language, I think I would tend to steer away from Perl...well, at least away from "full Perl" (see next paragraph)...not because it is too difficult or not because the padawans wouldn't be well served by it...but because it SO flexible that grappling with it distracts too much from what, IMHO is the nexus of that initial experience in programming...learning to formulate your problems in ways that can be solved (or helped) by programming a computer.
I recently read the book Minimal Perl and found it to be really attractive as a candidate 'first language'...it hides so much of the depth and complexity yet still provides an excellent foundation for moving into that complexity if it is needed. It reminded me of what I liked about Basic...simple to learn, easy to experiment with, and it provides all the functionality that any beginning programmer needs...yet could allow the padawan to focus on learning to Think like a programmer rather than on any more complexity than is absolutely essential to allow that learning. I don't necessarily think Perl is unique in this regard; but my experience with C, C++, Java, Lisp, COBOL, Ada, and others is that they, much like Fortran was for me, have too much syntactic and structural baggage that detracts from what, to me, is that important "first step" in programming.
Of course, with all the power and strength of OO-programming (a concept that I am still trying mightly to "get my arms around"...having grown up with and immersed in the procedural programming paradigm)...is an important consideration and is a way of thinking and structuring problems. I think that deserves consideration for a "first contact" with programming, too. And the great thing about Perl is that, with a different "minimal Perl", that paradigm could also be easily developed and learned by beginners. In fact, that's exactly how I'm teaching myself the basics of OO-programming...for me Perl is a much easier learning-ground than Java (which is what I first tried to use to learn about OO-programing).
So I guess I've talked myself into believing that Perl (at least with some variation on "minimal Perl") is and ideal first language.
|
---|