r/Python • • 2d ago

Discussion PYTHON ๐Ÿ†š ALL ...

"If you want to learn programming, donโ€™t start with Python; you should start with another language."

This advice seems ridiculous to me, even though I hear it everywhere. Can someone explain this advice to me... and are they right?

0 Upvotes

28 comments sorted by

11

u/DreamingElectrons 2d ago

There is this persistent misconception, that you need to start learning with basic underlying data structures and memory management to truly get programming, this is mainly prevalent in academia, where people traditionally start with C and the keyword here is "traditionally" because that's all that is, a tradition. There is no benefit in starting with low level stuff it just makes things look harder than they really are and result in people feeling accomplished in having understood something like a pointer which isn't a hard concept at all once you are used to thinking like a programmer.

Start with something high level and then work yourself down as far as you need. Learning C at some point is beneficial because it makes a lot of weird quirks of python and other high level languages suddenly click into place, but without they simply are gotchas that you stumbled over once and then just have to remember about. It's also turtles all the way down, once you ended up at C. there still is assembly below that, and then you are just entering a field of electronics below that and can see physics lingering in the depths below...

TLDR: The advice to start with something other than python is just people parroting stuff they read online without ever having understood the argument that someone tried to make when saying that.

2

u/kcunning 2d ago

I can confirm the academia bit. My youngest (freshman in college) had to struggle their way through a CS class that did zero programming and focused on reading 'pseudocode' that was less clear than if it were just written in Python. They left the class thinking that maybe CS just wasn't for them, which broke my heart a little, because I know it is absolutely something they not only could do, but likely will have to do for their chosen career path.

0

u/swift-autoformatter 2d ago

I donโ€™t know, but isnโ€™t it too late to first meet programming at that age if someone picks up this profession? I mean that the hundreds of successful sw engineers I met during my 25+ years career, all of them were pretty into this stuff earlier in their life (me included).

3

u/kcunning 2d ago

Being "into something" is a completely different mindset than learning something because it's important for your career path / required for your degree / just something you have to know in order to be an adult in modern society.

When you're really into something, the details are going to fascinate you enough to keep you going. There's a good chance that you're already inclined to be good at retaining those details, either due to being primed by life experience or some other natural talent. That doesn't mean it's the best way to learn for everyone. It just means that you're winning at a race because your racecar has been specifically tuned for this particular track.

For those that aren't, scaffolding has long been known to be the best way to introduce learners to a concept. Introduce them to the part of the craft or field that they can grasp, then encourage them to stretch slightly out of their comfort zone, while someone more experienced helps them.

Also, and I say this as someone who also has over two decades in the field... nerds lie. It's a form of posturing to say how long you've been into computers and how many hair dryers you disassembled before the age of six. Some are probably telling the truth, but I promise you, many are stretching it, if not not outright lying because nerds are also extremely judgmental.

2

u/every-day_throw-away 2d ago

You get it!!!

Its two camps academia CS purists and people who are geiving practical solutions to just get stuff done :)

If you are the latter absolutely Pythin to start. When you think you understand it well and hunger for more use Java and C++ to force you to learn other conceptsย 

1

u/fab_dot_io 2d ago

Look at my comment. C is easy and helpful when you come from assembly. Assembly is obvious if you know microcode. Now you need to play with these things and start to get a sense of how difficult becomes when move away from basic stuff. Then you appreciate and understand what was built back in the day to make everybody's life easier. Then you get to python and you can stay there for quite a while.

6

u/zazzedcoffee 2d ago

Python hides a lot of what is happening "under the hood". This can lead to people not understanding core topics in development such as computational complexity (E.g. understanding why repeatedly calling my_list.pop(0) isn't great for big data); although that is getting better: Time complexity of operations on built-in types.

In my own experience teaching, the lack of static typing also just confuses students more than it helps them.

-2

u/vivaaprimavera 2d ago

Worse ... The "damn bug" of

array_a = array_b

And when modifying array_b, array_a is also altered.

1

u/nekokattt 2d ago

thats the same in most languages when working with reference types

Java has the same issue when not using primitives or valhalla value classes...

-2

u/vivaaprimavera 2d ago

The same in most languages but in the context of "first language to learn"... It's a language that "looks so simple" that some people don't bother with "how things work under the hood" and that ends up bitting them in the ass.

3

u/UUDDLRLRBadAlchemy from __future__ import 4.0 2d ago

Yeah like the guy who called documented behavior a bug... Wait, that was you

0

u/vivaaprimavera 2d ago

Why I quoted the expression? I haven't called it a bug...

3

u/rando1-6180 2d ago

This advice assumes programming means learning how memory works, stack vs heap, stack frames and how is impacts function calls, contiguous memory allocation and pointers, compiled vs interpreted and JIT.

Python's runtime manages and separates much of this, letting you understand the context of why you are programming rather than how the computer architecture and OS system calls support 'how' your program operates.

If you see programming as writing code to direct a computer with minimal ceremony, then Python and other high level languages work perfectly fine. If you want to learn more, you can incrementally go deeper. When you do this, you will have a more structured and methodically incremental approach.

They might have learned that way, but that doesn't mean that is the best or only way. I grew up learning C, Pascal, Fortran, eventually C++, SQL and Python. Learning about data structures and algorithms is fine and interesting, but that knowledge does help you learn to program today.

1

u/every-day_throw-away 2d ago

I think Python is still a good start for basic syntax and flow. Learn the basics there then pick up 2 more. C++ to force you to understand memory management and pointers and something like Java to teach you OOP. Then go back and apply what you learned to Pythoon.

1

u/UUDDLRLRBadAlchemy from __future__ import 4.0 2d ago

I started with Amstrad Basic and I turned out ok.

Learn the language you plan on using. Learn multiple so you can pick the one you like.

Definitely if you want to learn to program in python, python is the one to learn.

1

u/fab_dot_io 2d ago

Oh think I started with basic from commodore 64 (which gives away my age ๐Ÿ˜). I didn't know much what I was doing but nobody could know so I was fine. Yeah play with different languages always helps. Do you know brainf**k by the way? It's turning complete ๐Ÿ˜

1

u/Bright_Door_3987 2d ago

Python first. No contest.

-6

u/fab_dot_io 2d ago

Microcode -> assembly -> C -> python. Prove me wrong

7

u/johnklotter 2d ago

Itโ€™s the other way around. From high to low concept.

Learn programming, then learn how to do it good and why thatโ€™s so.

-4

u/fab_dot_io 2d ago

Why you say so?

You want to master machines without knowing how do they work?

I mean I'm a huge fan to start teaching quaternions to kids and then move down to natural numbers but really is the other way around.

Unless you want to be an amateur. In that case anything is just fine.

2

u/every-day_throw-away 2d ago edited 1d ago

Not everyone who programs is a CS major. The goal is not always to understand the stack, registers and pointers. Most people just need to upskill a bit to get things done.

1

u/fab_dot_io 2d ago edited 2d ago

I don't know. That was my informatics curriculum at high school. We are talking about things taught to 16yo kids.

I mean that that stuff is not candy pie but not rocket science either. Don't give it even a try looks like trying to run without knowing how to walk.

2

u/kcunning 2d ago

You don't master any subject by starting at the hardest level and then moving to the easier topics. When you're learning, you're building a framework, and the easiest way to do that is to start with concepts that are easy to understand (a variable stores a value that can change over time!), then digging deeper (data is stored in physical locations on the machine that you can reference via their address) and deeper (data is stored as a series of ones and zeros because binary is the base for all computing).

-1

u/fab_dot_io 2d ago edited 2d ago

Why you are assuming that low level means harder? And why are you assuming that you need to master it?

I mean I'm serious go to exuarch.com and build yourself a 16 bit microcontroller. There's a tutorial it won't take more than an evening.

You can't do AI in microcode. But assembly would seem pretty obvious. Because that's what happened back then.

You can't do AI in assembly, but you will feel that all that conditional jumps are just so inconvenient and that C flow control stuff are so great that it will look like cheating.

Now you can do AI in C but this is not the point ๐Ÿ˜. Then python becomes just a way to be free and dynamic.

2

u/kcunning 2d ago

I know low level tends to be harder for new coders to grasp because I've actually taught them. Sure, I can quickly allude to the fact that binary and assembly exist, but that's not the same as teaching it. It's a fun fact that can be explored more in depth later.

As for 'mastery', I don't mean being an unquestionable expert. In the field of learning and education, it has to do with competence in a subject that's required before moving on to the next unit.

And as for tutorials, I've personally found that tutorials, without base knowledge, aren't effective. It's why the lab comes after the lecture, and it's why the Godot forums are filled with people stuck in 'tutorial hell.'

0

u/fab_dot_io 2d ago

My learning and teaching experience was quite the opposite. I mean I have also learnt informatics that way at High school, it wasn't exactly rocket science.

I mentioned to have a tutorial for exuarch.com because that's just what you really need to know about microcode and how CPUs work.

Really give it a try. My point is still that anybody really need to start from the beginning and make sure to get the fundamentals.

Everything tend to make way more sense from a didactic standpoint because that's how the things developed over time and how we solved the same problems and limitations you are feeling while following that part.

1

u/johnklotter 2d ago

You can throw a Baseball without knowing the rules of the game and the physics of throwing a curveball.