Set in Python PYTHON by Ravinder Nath Rajotiya - April 10, 2022April 11, 20220 SETS in PYTHON A set is an unordered collection of items. Every element of a set is unique, i.e. there are no duplicate. A set itself is a mutable i.e. we can add or remove items in a set. Items of a set are immutable i.e. we cannot modify items of a set using its index. A set is declared using {} or in-built set() function How many items in a set: A set can have any number of integer, float, tuple, string types etc s={3,5,”Hello”, 3.14} What cannot be in a set: A set cannot have mutable elements like lists, sets or dictionaries as its elements. So it will be wrong to create a set: >>>s={3,5, [6,7], 3.14} error – set cannot have list as the set