Live data from Hacker News

The Origins of Python

inference-review.com

11–20 of 73 posts

Re: The Origins of Python

#11
post #9

I feel Python changes and have changed too much to be a good introduction language anymore. It is not possible for a from zero beginner to read ordinary Python code with decorators, generators or what not and understand it. Way too many concepts. It is being choose by intertia at this point and have been ruined for the original target user by former target users who are now professional programmers using it at work.

I feel like python has never been a good introduction language. It is simply too abstract and hides too many details that are often required in other languages (Python is simply too flexible). It is good to learn if you are only scripting or calling library API, but I feel like it is a poor starting point if the goal is to transition into languages with more rigid structures such as C++.

Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once.

This absolutely provides a good foundation to learn lower level concepts later, although going bottom-up and starting with a language like C is also a valid path.

It’s also worth noting that a large proportion of developers will never learn C++, and will stick to higher level languages their entire career. And another chunk will only learn the lower level stuff much later when they have many years of experience to lean on.

If your goal is to immediately become a C++ developer, then you should learn C++, but that isn’t most people learning to program.

Re: The Origins of Python

#12
post #8

I feel Python changes and have changed too much to be a good introduction language anymore. It is not possible for a from zero beginner to read ordinary Python code with decorators, generators or what not and understand it. Way too many concepts. It is being choose by intertia at this point and have been ruined for the original target user by former target users who are now professional programmers using it at work.

Large code bases are always going to be hard to read for beginners. As an introduction language, I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc. You can perfectly write python without all the fancy stuff. In fact, there are quite a lot of data scientists who are paid to write python and don't know the first thing about concepts…

> I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc.

I think the point here, is that when beginners start exploring what's out there in "professional" lands they'll quickly discover that they don't know Python at all, because they were using this primitive subset of a language.

Re: The Origins of Python

#13
post #9

Earlier quoted context omitted.

I feel like python has never been a good introduction language. It is simply too abstract and hides too many details that are often required in other languages (Python is simply too flexible). It is good to learn if you are only scripting or calling library API, but I feel like it is a poor starting point if the goal is to transition into languages with more rigid structures such as C++.

Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once. This absolutely provides a good foundation to learn lower level concepts later, although going bottom-up and starting with a language like C is also a valid path. It’s also worth noting that a large proportion of…

>>> Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once.

I wonder if whether this is a blessing or a curse depends on the person who is learning it. For instance, my first language was BASIC in 1981, and so my gut reaction to discussions about learning languages is that BASIC lets you at least imagine the workings of the machine that's running your program. The teacher can draw boxes on the blackboard to explain 10 LET X = X + 1

And we weren't far from the machine. There were not very many turtles on the way down to the level of logic gates. I also learned how a microprocessor worked, reading books as a high school kid, and articles in Byte Magazine, something that would be laughable for today's big CPU's.

That's a bottom-up approach. For others, a top-down approach might be better, e.g., seeing mathematical equations develop, in beautiful notation, without caring what the machine is doing under the hood.

Another comment in this thread mentions the ability to read code. Python has sprawled. I've been coding in Python for 10 years (as a "scientific" programmer) and recently took a Python skills quiz. I mentor beginners. Yet I scored barely at the top of "average." I can't read the code that's in a lot of the more elaborate Python packages.

A problem is motivating people to learn a learning language when they know that they'll outgrow it.

Re: The Origins of Python

#14
post #9

I feel Python changes and have changed too much to be a good introduction language anymore. It is not possible for a from zero beginner to read ordinary Python code with decorators, generators or what not and understand it. Way too many concepts. It is being choose by intertia at this point and have been ruined for the original target user by former target users who are now professional programmers using it at work.

I feel like python has never been a good introduction language. It is simply too abstract and hides too many details that are often required in other languages (Python is simply too flexible). It is good to learn if you are only scripting or calling library API, but I feel like it is a poor starting point if the goal is to transition into languages with more rigid structures such as C++.

C++ is way too big to be an introduction language, and modern C++, especially with STL, also hides a lot.

You could choose a subset of C++ or just teach C (which would be my preference)

Re: The Origins of Python

#15
post #9

Earlier quoted context omitted.

I feel like python has never been a good introduction language. It is simply too abstract and hides too many details that are often required in other languages (Python is simply too flexible). It is good to learn if you are only scripting or calling library API, but I feel like it is a poor starting point if the goal is to transition into languages with more rigid structures such as C++.

Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once. This absolutely provides a good foundation to learn lower level concepts later, although going bottom-up and starting with a language like C is also a valid path. It’s also worth noting that a large proportion of…

While learning, hiding details is important, but Python overdoes the abstraction. `for` loops and iterator based loops have been merged into one thing, and I am sure people write `for i in range(10)` without a good understanding of what the `range` function does. Even strings blur the line between individual characters and actual strings. The lack of clarity at these basic concepts is precisely why Python is not suitable as a first language, since it hides concepts that are prevelant in all other mainstream languages. As a result, I have often seen students develop bad coding habits and poor mental model of why their code works. Instead of learning proper programming concepts, they just know the syntactic sugar and abstractions that Python offers.

I do agree that Python provides a very small startup cost to writing code, the details are sacrificed to acheive this. This may be useful to capture interest/generate motivation and get a quick prototype/"helloworld" out, learning Python is only good for learning Python, not for programming in general.

Re: The Origins of Python

#16
post #6

I feel Python changes and have changed too much to be a good introduction language anymore. It is not possible for a from zero beginner to read ordinary Python code with decorators, generators or what not and understand it. Way too many concepts. It is being choose by intertia at this point and have been ruined for the original target user by former target users who are now professional programmers using it at work.

Ease of use and ease of learning are often at odds with performance. A go-kart is easier to learn and to drive than a Formula 1 car.

Throwing money/time/effort at it sometimes changes things. Javascript and PHP do pretty well on some specific workloads now for example.

Re: The Origins of Python

#17
post #15

Earlier quoted context omitted.

Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once. This absolutely provides a good foundation to learn lower level concepts later, although going bottom-up and starting with a language like C is also a valid path. It’s also worth noting that a large proportion of…

While learning, hiding details is important, but Python overdoes the abstraction. `for` loops and iterator based loops have been merged into one thing, and I am sure people write `for i in range(10)` without a good understanding of what the `range` function does. Even strings blur the line between individual characters and actual strings. The lack of clarity at these basic concepts is precisely why Python is not suit…

Frankly I think classic c-style for loops are a terrible abstraction for beginners. Iterator based loops make sense on a high level ("I don't care how it works, I only care what it does"). And while loops make sense on a low level ("I can see how each piece works"). To a beginner, c-style for loops are just an obscure, implicit syntax for while loops.

> Even strings blur the line between individual characters and actual strings

IMO that's better than what C++ does, where it pretends that a character is a single byte. Whereas most code nowadays is using unicode, which means that code will break as soon as they try to store a non-ascii character in it.

Re: The Origins of Python

#18
post #8

Earlier quoted context omitted.

Large code bases are always going to be hard to read for beginners. As an introduction language, I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc. You can perfectly write python without all the fancy stuff. In fact, there are quite a lot of data scientists who are paid to write python and don't know the first thing about concepts…

> I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc. I think the point here, is that when beginners start exploring what's out there in "professional" lands they'll quickly discover that they don't know Python at all, because they were using this primitive subset of a language.

But you always start by using a primitive subset of a language.

Re: The Origins of Python

#19
post #15

Earlier quoted context omitted.

Python is a good learning language precisely because it hides those details. This allows people to the learn the basics like variables, loops, strings, etc without getting overwhelmed with too much at once. This absolutely provides a good foundation to learn lower level concepts later, although going bottom-up and starting with a language like C is also a valid path. It’s also worth noting that a large proportion of…

While learning, hiding details is important, but Python overdoes the abstraction. `for` loops and iterator based loops have been merged into one thing, and I am sure people write `for i in range(10)` without a good understanding of what the `range` function does. Even strings blur the line between individual characters and actual strings. The lack of clarity at these basic concepts is precisely why Python is not suit…

If you can understand the “for i in” part means then range should not be hard to grasp. I would argue that someone new to programming with even a modicum of logic might be able to guess what range does easily .

Re: The Origins of Python

#20
post #8

Earlier quoted context omitted.

Large code bases are always going to be hard to read for beginners. As an introduction language, I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc. You can perfectly write python without all the fancy stuff. In fact, there are quite a lot of data scientists who are paid to write python and don't know the first thing about concepts…

> I don't see why you would need to use decorators, generators or anything? You don't need to learn control flow, functions, variables, etc. I think the point here, is that when beginners start exploring what's out there in "professional" lands they'll quickly discover that they don't know Python at all, because they were using this primitive subset of a language.

But in what language is that not true? You start learning any language by pieces, and just because you know 10% of the language doesn't mean you're ready to write it professionally, this is true for any language.
Post reply on HN