What will be the output of the following Python code snippet?
l=[1, 2, 4, 5, 2, 'xy', 4]
set(l)
l
l=[1, 2, 4, 5, 2, 'xy', 4]
set(l)
l
A. {1, 2, 4, 5, 2, ‘xy’, 4}
[1, 2, 4, 5, 2, ‘xy’, 4]
B. {1, 2, 4, 5, ‘xy’}
[1, 2, 4, 5, 2, ‘xy’, 4]
C. {1, 5, ‘xy’}
[1, 5, ‘xy’]
D. {1, 2, 4, 5, ‘xy’}
[1, 2, 4, 5, ‘xy’]
Answer: Option B
Join The Discussion