flâneur — a map of the web's best reading

Style | Course Readings | 6.101 Fall 2022

py.mit.edu · 24 words · saved by 1 readers

People often refer to "good style" when talking about programs/code, but, interestingly, that word can mean a lot of different things depending on context. In this document, we'll try to explain what "good style" means in the context of 6.101, as well as to provide some suggestions for incorporating elements of "good style" into your own programs. One notion of style relates to detailed character-by-character desisions about how code is formatted, like how much whitespace to use when indenting, where parentheses should go, etc. The Python Software Foundation does publish/maintain an official style guide called PEP 8, and this convention is probably the most widely-used style convention for Python code, so it's not a bad idea to get into the habit of following those guidelines. That said, while conventions related to this notion of "style" are perhaps worth knowing and caring about, we are not going to focus on them in 6.101 (you are welcome to put your parentheses wherever you like so

Style | Course Readings | 6.101 Fall 2022 Course Notes: Style this page (from a previous semester) is no longer accessible, except for staff

Explore this link on the map →

related reading