Description
In this course, you will learn :
- Discover some tools and tricks that every Python programmer should know in order to avoid common blunders.
- Consider the course to be a “Python hacks” handbook.
- Learn to work with Python's unexpected quirks
- Avoid some of the more common errors Python developers come across
- Writer better Python code
Syllabus :
1. Slippery Slopes
- Stubborn del Operation
- The Out of Scope Variable
- Deleting a List Item While Iterating
- A Tic-tac-toe Where X Wins in the First Attempt!
- Lossy Zip of Iterators
- Loop Variables Leaking Out!
- Modifying the Dictionary While Iterating Over It
- Solution Review: Sudoku
- Name Resolution Ignoring Class Scope
- Beware of Default Mutable Arguments!
- Catching the Exceptions
- Same Operands, Different Story!
- Can I Call You Later?
- What's Wrong With Booleans?
- Class Attributes and Instance Attributes
- Quick Quiz!
- Splitsies
- Wild Imports
- Let's Mangle
- All Sorted?
- Midnight Doesn't Exist?
- Needles in a Haystack
- More Needles in the Haystack
2. Strain Your Brain!
- First Things First!
- Strings Can Be Tricky Sometimes
- Be Careful With Chained Operations
- How Not to Use the "is" Operator
- Hash Brownies
- Deep Down, We're All the Same
- Disorder Within Order
- Keep Trying...
- For What?
- Quick Quiz!
- Evaluation Time Discrepancy
- 'is not... ' Is Not 'is (not ...)'
- The Chicken and Egg Problem
- Subclass Relationships
- All-true-ation
- The Surprising Comma
- Strings and the Backslashes
- Not Knot!
- Half Triple-quoted Strings
- Quick Quiz!
- The Mysterious Key Type Conversion
- Non-Reflexive Class Method
- Yielding None
- Yielding From...Return!
- Nan-reflexivity
- Mutating the Immutable!
- The Disappearing Variable From Outer Scope
- Let's See If You Can Guess This?
3. Appearances Are Deceptive!
- Skipping Lines?
- Teleportation
- Well, Something Is Fishy...
- Quick Recap
4. The Hidden Treasures!
- Okay Python, Can You Make Me Fly?
- 'goto', but Why?
- Brace Yourself!
- Let's Meet Friendly Language Uncle for Life
- Even Python Understands That Love Is Complicated
- Yes, It Exists!
- Ellipsis
- Inpinity
5. Miscellaneous
- '+=' Is Faster
- Let's Make a Giant String!
- Slowing Down dict Lookups
- Bloating Instance dicts
- Minor Ones
- More of These
- This is the End