- Home
- Course Detail
regularpython@gmail.com
You are now watching:
Python Sets / of Python Set Basic Examples
# A Set is an unordered collection data type that is iterable, mutable, and has no duplicate elements student = {"Ram", 200, 205.04} student = {"Ram", 200, 205.04,200, 200, "Ram"} print(student) # update sets student.add("krish") print(student) # Frozensets # Frozen sets are immutable objects that only support methods and # operators that produce a result without acting the frozen set or sets to which they are applied. student = frozenset(["Ram", 200, 205.04]) student.add("krish") print(student)