Write a Python program to Check is a set a subset of itself


In the program, a set a is created with elements 1, 2, 3, 4, 5. The issubset() method is used to check if a is a subset of itself. The method returns a Boolean value indicating whether one set is a subset of another set. The result of a.issubset(a) is True, which indicates that the set a is a subset of itself. The result is printed to the console with the message "A Subset of Itself(A) : True".

Source Code

a = {1,2,3,4,5}
print("A Subset of Itself(A) :",a.issubset(a))

Output

A Subset of Itself(A) : True