The quiz where the difficulty automagically adapts to the player's Python knowledge
This is a question page. You can use this page to bookmark a question. Start a new quiz!
Question #602
print(list({1, 2, 2, 2, 4, 5, 2}))
{1, 2, 2, 2, 4, 5, 2} is a set. It is distinguishable from the curly brackets around it. As {1, 2, 2, 2, 4, 5, 2} is a set, duplicate values are removed first. The first 2 stays while the others are removed. After being transformed to a list, the object becomes [1, 2, 4, 5] . (docs.python.org/2/library/sets.html)
Question difficulty: 🔵🔵🔵🔵🔵