# Take input from the user for two sets
set1 = set(input("Enter the elements of the first set, separated by spaces: ").split())
set2 = set(input("Enter the elements of the second set, separated by spaces: ").split())
# Find the intersection of the two sets
intersection = set1.intersection(set2)
print("The intersection of the two sets is:", intersection)
# Find the union of the two sets
union = set1.union(set2)
print("The union of the two sets is:", union)
# Find the difference between the two sets
difference = set1.difference(set2)
print("The difference between the first set and second set is:", difference)
# Check if set1 is a subset of set2
is_subset = set1.issubset(set2)
if is_subset:
print("The first set is a subset of the second set.")
else:
print("The first set is not a subset of the second set.")