Learn how to write more idiomatic and Pythonic code with tips, conventions, and idioms.

8m read timeFrom bit.ly
Post cover image
Table of contents
Identity and Equality ComparisonsContext Managers Instead of try/finallyChecking If Parameter Was ProvidedMultiple AssignmentVariable UnpackingSwapping ValuesProcessing Lists in ParallelAvoid map , filter and reduceBatteries IncludedThe "Bunch" IdiomConclusion

Sort: