Python Set Comprehensions: How and When to Use Them - Real Python
Briefly

Set comprehensions provide a concise and efficient way to create sets in Python, enhancing readability and reducing code length compared to traditional approaches.
To create new sets in Python, you can use set literals enclosed in curly braces, which allow hashable objects to form unique collections without duplicates.
Using the set() constructor, you can generate a set from an iterable, automatically filtering out duplicative elements while maintaining the uniqueness property of sets.
The .add() method allows you to add new items to an existing set, but remember that sets inherently do not maintain any order.
Read at Realpython
[
|
]