Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

create set in python

# Different types of sets in Python
# set of integers
my_set = {1, 2, 3}
print(my_set)

# set of mixed datatypes
my_set = {1.0, "Hello", (1, 2, 3)}
print(my_set)

my_set = set()
// initialize empty set in python
Source by www.programiz.com #
 
PREVIOUS NEXT
Tagged: #create #set #python
ADD COMMENT
Topic
Name
8+3 =