Python Snippets A Closer Look at Python's Print Function Print is one of the first functions we encounter when learning Python, but it can do a lot more than say "Hello, world!". Learn about print's other options and master this common function!
Learn Python Programming Destructuring in Python In this post we take a look at destructuring, also called "unpacking". We can use it to split a collection into single values, e.g. for multiple assignment.
Python Snippets Python Easter Eggs This week we take a look at some of Python's hidden Easter eggs, including perhaps the most important module in all of Python: antigravity.
Coding Interview Problems Coding Interview Problems: Rotating a List In this post we tackle another common coding interview problem: rotating a list. Avoid common pitfalls and impress at your next coding interview.
Python Snippets Python Deques Deques are a very handy collection type from the built-in "collections" module. They extend the functionality of lists and give us a couple more useful methods. Learn about them in this post!
Python Snippets Python Itertools Part 2 - Combinations & Permutations This week we continue our look at the itertools module, this time covering the permutations and combinations functions.
Coding Interview Problems Coding Interview: Find the Longest Word In this post we tackle another common coding interview problem: finding the longest word in a paragraph. Avoid some common pitfalls and ace your interview.
Python Snippets Python Itertools Part 1 - Product The itertools module contains a bunch of handy functions. Here we take a look at product, which can serve as a replacement for complex comprehensions.
Python Snippets Python's symmetric_difference Method for Sets In this Python snippet post we cover a lesser known set method: symmetric_difference.
Python Snippets Python Comprehensions with Conditionals In this snippet post we show you how to add conditional clauses to your list comprehensions. Once you know how to use it, this kind of filtering is very powerful.
Coding Interview Problems Coding Interview Problems: FizzBuzz In this post we provide a walk through for a common interview problem: FizzBuzz. Avoid some common mistakes and breeze through this problem in your next coding interview.
Python Snippets List Comprehensions in Python Learn how to use Python's list comprehension syntax: an awesome, Pythonic tool for creating new lists from existing iterables.
Learn Python Programming Creating a New Sequence Type in Python - Part 3 In this post we continue our journey to create a new sequence type using classes and Python's special methods. This time we focus on operator overloading!
Python Snippets Python's Enumerate Function In this Python snippet post we take a look at the enumerate function: a vital tool for creating Pythonic loops.
Coding Interview Problems Coding Interview Problems: Reversing a List (Python) Reversing a list is one of the most commonly asked interview problems. It's asked to test fundamental knowledge and also your problem-solving skills. In this post we look at a couple different ways to reverse a list easily!
Python Snippets Python Set Operators In this post we cover shorthand operators for performing set operations in Python. We'll look at the three most common ones: union, intersection, and difference.
Python Snippets Quick Sequence Reversal in Python Python lists have a handy method called reverse, but it's not always what we want. For a start, we can't use it on other sequence types, like tuples and strings, and it also
Learn Python Programming Creating a New Sequence Type in Python - Part 2 In this post we continue our journey to master Python's dunder methods by creating a new sequence type from scratch.
Python Snippets More Uses for Else in Python Get familiar with the different uses for else in Python. It's not just for if statements: we can use it with loops, and for error handling too!
Learn Python Programming Creating a New Sequence Type in Python - Part 1 Learn to exploit the power of Python's magic methods by creating a new sequence type from scratch!
Learn Python Programming Python Slices Part 2: The Deep Cut In this post we take a deeper dive into Python slices, and pull back the curtain on the magic methods behind the slice notation we covered in earlier posts.
Learn Python Programming Python Slices Slices are amazing whenever you want to use a piece of a larger sequence. Learn the basics of slicing in Python and add a powerful tool to your repertoire.
Learn Python Programming Rounding in Python Take a deep dive into Python's rounding functions! Learn about floor, ceil, trunc, and round, and avoid common rounding errors in Python.
Learn Python Programming Python's modulo operator and floor division Learn about the some less well-known operators in Python: modulo and floor division—as well as how they interact with each other and how they're related!