Recently, I read a couple of blog posts about how they learned Python or just attempted to learn. I commented on the posts, but I feel it’s a good timing to write about how I learned Python and what I think about how people should learn.

This post might sound very opinionated, and it sure is. Please feel free to respond to my points or add how you learned Python.

1   tl;dr bullet points

You only need to learn Python with two things:

  • Python interactive mode, i.e. $ python
  • A good tutorial, the official one is more than enough.

More than these are just creating unnecessary burdens or obstacles on your learning course, interference, and confusions. Beside the tools, you also need to have:

  • Sense of logic
  • Mathematics: algebra (minimum)
  • Reading skill
  • Patience

Keep simple and essential.

2   How I learned?

If I recall correctly, I began in 2006, the time around Python 2.3 or 2.4. I was still a Windows user back then, so I actually learned Python on Windows and even coded and packaged a program for using with iTunes.

When I started, I simply picked one tutorial after installed Python. I sat down and spent an entire day reading the tutorial and that’s how I learned Python.

You don’t need any fancy IDE, you don’t need to sign up any classes. The only things you need are listed in previous section, plus little time and patience.

Python is a great programming language, it’s worth learning if you can code. I still remember when I first read about its list comprehension syntax, I was so amazed by it.

3   Not everyone can code

First of all, everyone should realize that not everyone can code. It’s good that someone wants to learn about programming, but it’s just not a thing for everyone.

I don’t understand why other programmers and organizations think everyone can code, even believe that there was a need for that. I believe there is even a term like “code literacy”

It’s just terrible idea to establish. Coding is just like an art or any profession. Not everyone has the gene in their blood.

If you can’t code, then you can’t. If someone can’t code, then they just can’t code. Don’t try to push it. Lots of bad coders around, who are just better off coding once and for all. I am quite glad Python doesn’t seem to have those bad coders as many as PHP and JavaScript have.

I sometimes blame television show for faking computer scenes, those make people think coding is just as how they look on television. Let me tell you this: those are 100% rubbish, nothing is even real. Yes, they look cool, but just a scene pieced with fake stuff.

4   Why no IDE

I strongly recommend not learning Python or any programming language with an IDE. Why?

  • Because you need to learn syntax right first.
  • Because you don’t need an IDE to tell you about function arguments when you are just a beginner.

Follow tutorial, read every word. Once you know how to code in correct syntax, then you can think about IDE if you really need one.

If you use IDE, you may not even think about reading any manuals, but just pull in whatever IDE gives you, and that’s when a land mine might slip into your code because you simply don’t know entirely what you put into your code.

Learning with IDE can give you a false sense about the language, and possibly blind you. IDE is a nice tool, but only after you have learned the programming language.

5   Library Reference

When I code in Python, the only extra tool I have is Vim while coding. Nothing else, no IDE, no debugger, no completions. So, how do I know how to use a library? I check up the reference manual.

Python’s documentation is a bit different, it might take you a moment to get used to them. But once you are familiar with its flow and typesetting, it becomes very easy. Reading descriptive text about arguments is quite enjoyable.

Years ago, almost two decades ago, I had printed Reference manuals of Delphi. Several heavy books, I read them, function by function, VCL by VCL, it was a fun time. I also read ECMAScript standard specification, you can learn quite something from reading specification, even it’s quite technical.

Reading is important just like everything.

6   Be patient

If you want to be a good programmer, then be patient, or just don’t bother trying to learn coding—and anything.

From time to time, I saw really scary code and whoever coded the piece wasn’t even aware of how terrible the code is. You can tell by just reading the code that the person hadn’t even gone through any tutorial.

Some like

  • can’t even write in correct syntax
  • can’t even use print statement (Python 2) right
  • incorrectly indent the code, not meaning PEP 8 by any means, it just adds space at wrong place
  • use eval when there is absolutely no need for that
  • worst of all: typo

Simple typo and doesn’t even bother to search the error message. If they do, the search engine probably have corrected for them.

I can’t understand the frustration for new learners, but sometimes it’s just simple mistake. Cool you ahead and review everything. If you have done right, that’s learn the correct syntax first, most of time, you wouldn’t have any problems.

Be patient, learn the syntax right first and only once.

7   Closing words

I agree that Python is easy to learn, but that also means it’s easy to make mistakes when you are careless.

Lots of people don’t even know about basic things, and produce awful codes while believing they have achived something. Recently, I’ve tried to point out for them potitely without sounding over judgemental, but I actually want to tell them: Go back and read through the tutorial.

Try to learn Python at once.