Skip to content

Python Sets

Python Set Intersection Guide with Examples Cover Image

Python Set Intersection: Guide with Examples

In this post, you’ll learn how to find the intersection between two or more sets in Python. Sets in Python are a built-in data type, where items are unordered, unindexed, and unique. By finding the intersection between two or more

Python frozenset: Overview and Examples

Python frozenset: Overview and Examples

In this tutorial, you’ll learn how to use the Python frozenset data structure. The frozenset in Python is often overlooked and many Python users don’t even know that it exists. The frozenset is a data structure that emulates the set,

Find Duplicates in a Python List Cover Image

Find Duplicates in a Python List

In this tutorial, you’ll learn how to find and work with duplicates in a Python list. Being able to work efficiently with Python lists is an important skill, given how widely used lists are. Because Python lists allow us to

How to Remove Items from a Python Set Cover Image

How to Remove Items from Python Sets

In this tutorial, you’ll learn how to remove items from a Python set. You’ll learn how to remove items using the remove method, the discard method, the pop method, and the difference_update method. You’ll learn the differences between each of