Probably you mean no chance of a compiler/interpreter error, because the program almost surely will not do what the rookie meant, much to his/her surprise. That's an error in my book :)
I agree with the rest of the benefits of Python as a beginner language.
Completely disagree, what you describe is more "Software Engineering" than "Programming".
To me, learning to program means learning to describe the way to solve a problem in fully comprehensive and exhaustive steps, with a very limited set of tools and primitives to work with (data, operations and flow control to begin with). You can do that in any language, so your choice is really up to convenience and context.
As the basic tools of programming become second nature and problems to tackle become larger, then it's time to move into SE, abstractions, organization and etc. You can still do that teaching in pretty much any language.
I think that a huge proportion of programming is about understanding and creating abstractions. But hey, I was brainwashed by SICP (http://mitpress.mit.edu/sicp/) back in college.
> You can do that in any language, so your choice is really up to convenience and context.
Given two people of equal ability, and without any background in programming, I think that the person who learns Python will advance more quickly than the person who learns C. They will understand fundamental programming concepts sooner, and will be able to apply that knowledge sooner.
This doesn't mean that C is bad, but rather that it was designed to solve certain problems, while Python was designed to solve other problems -- among them, the ease with which people can learn and use the language.
Learning C requires that people understand the memory model of the computer, on top of everything else that you need to know to programming, such as variables, conditionals, loops, and functions. Programming is hard enough for people to learn; by teaching them a language that lowers that threshold, they'll learn more in less time. They can always learn C down the road -- but if C is their first language, then they might (in my experience, from having spoken with many frustrated wannabe programmers) just give up on it.
My choice today is actually JavaScript, partly because of ubiquity, partly because it's very easy to do something interactive and visually interesting (Canvas), and partly because its simplicity soon leads into its shortcomings. Python as a language is "batteries included", and I believe in the value of students bumping into barriers and limitations so they can properly value the reasoning behind solutions. In that sense, the value of C is in teaching students about lifetimes and ownership of resources.
People should learn two programming languages at the same time, a very high level one such as Python, and a very low level such as C. Combining the top-down and bottom-up approaches to learning, simultaneously, yields the best results for most people. While learning Python, someone can begin to look inside the abstractions and get a feel for algorithmic complexity and such stuff. While learning C, someone can see how to use it to build an OS such as Linux.
I find this completely impractical. Programming is hard for people to learn. They're juggling all sorts of new concepts and ideas. It's hard for them to remember the terminology, the data structures, the ways in which functions work, or even when and if they should use functions. Teaching them two languages simultaneously would be far more confusing than helpful.
I'm all in favor of learning different approaches and different languages. But for someone without any background to learn two languages simultaneously would be making it more difficult, not less.
I agree with this. I think its a great way to understand how those new concepts and ideas work in two different universes. Its helped me separate and understand how core ideas and concepts work and how they can work different.
This is actually exactly why I like the idea of C as an introductory programming language. Most of the time it's very clear what you are doing there is no magic. Mathematics also involves abstractions and high-level thinking, but you don't start out with calculus or linear algebra. You learn the basics then you abstract them.
- It's dynamically typed. Say what you want about static vs. dynamic typing, but this is one less thing that newbie programmers have to get right. There's no chance of an error when they say "i = 'abc'", if you've defined i to be an int.
- It's interactive. The fact that you can "play" with the language within the interactive shell is a huge selling point. IPython and the IPython Notebook are easy to get working, and for people to work with.
- Python's restricted command set and simple, regular syntax let you concentrate on ideas: Yes, many newbies to Python (and to programming in general) get confused by indentation, blocks, colons, and the like. But they're going to get confused by the syntax of nearly any language. Python has a simpler syntax than most other languages, meaning that there's less to learn, and less to remember. This lets the new programmer concentrate on the ideas that they're learning, or the implementation of what they're doing.
- It's cross platform. The fact that people can use Python on any computer they like is a big selling point.
- You can easily teach object-oriented and functional-style programming. Python is obviously object-oriented, but can also be used to introduce functional programming. In this way, you can expose programmers not only to multiple paradigms in Python, but also in other languages.
- You can use it for real applications. People are often surprised to discover that real-life applications are being written and used in this language that they're learning, which seems so simple.
I'm sure that there are more reasons than these. But let's consider the alternatives that the article suggested:
- I would be hard-pressed to think of a worse first language than C. You want to introduce people to the concepts of programming, which means abstractions and high-level thinking. C forces you to think in terms of the computer and its memory, which is just the opposite. The fact that it's compiled to binary form, that you don't have an interactive C shell, and pointers are just three reasons why I think that C would be a very bad choice. Sure, everyone should learn C at some point -- although I often point out that I'm a much happier person since I moved to dynamic, high-level languages many years ago -- but if you want to teach the concepts of programming, C is going to require too much learning just to get simple things done.
- JavaScript has many good points for beginning programmers -- but the chief problem, in my mind, is the language's syntax, which is far too inconsistent and forgiving/flexible for newbies. I think that someone coming to JavaScript from Python will have a very easy time; the mapping of data types is fairly straightforward, and even the notion of passing functions is pretty easy to get. But the learning curve in JavaScript seems steeper to me than in Python, despite the obvious advantages of being able to work within a browser.