O’Reilly Learning Python is *my jam*

Vocabulary and notes from the book. Just started it today. It’s awesome.

mutable: object whose state can be changed after its creation.

>>> a=9
>>> a=11

immutable: object whose state cannot be changed after it’s creation.

Variables are just names, like a label you put on a drawer if you’re organizing your craft room. They reference the object, but aren’t the object themselves. (mind blown) They don’t hold the object, or store the object, or copy the object, they reference it. (again, mind blown).

class: the definition of an object. i.e. (in Python 3)

<class 'int'>
<class 'str'>

in python 2.7, it doesn’t say class, it says:

<type 'int>

They’re more or less the same thing.

More to come later.

Fun fact: open a Python shell, and run:

import this

And enjoy your moment of Python Zen :)

I, the rat, weave my way through the maze of programming, in search of the cheese. But is the maze itself the cheese?



I like to write :)

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store