What is list and set in Python?
Lists and tuples are standard Python data types that store values in a sequence.
Sets are another standard Python data type that also store values.
The major difference is that sets, unlike lists or tuples,
cannot have multiple occurrences of the same element and store unordered values.
What does set () do in Python?
set() method is used to convert any of the iterable to sequence of iterable elements with distinct elements, commonly called Set. Parameters : Any iterable sequence like list, tuple or dictionary. Returns : An empty set if no element is passed. Non-repeating element iterable modified as passed as argument.
コメント
コメントを投稿