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 #262
print(list(zip([1, 2, 3], ['a', 'b', 'c'])))
The zip() function returns a consolidated iterator that contains tuples holding adjacent values from input containers. (techbeamers.com/python-zip)
What is the output of the following code snippet?
— The Python Quiz (@thepythonquiz) August 30, 2020
print(list(zip([1, 2, 3], ['a', 'b', 'c'])))
[(1, 'a', 2, 'b', 3, 'c')]
[(1, 'a'), (2, 'b'), (3, 'c')]
[(1, 1), (2, 2), (3, 3), ( 'a', 'a'), ( 'b', 'b'), ('c', 'c')]#python #python3 #pythonprogramming #learnpython
Question difficulty: π΅π΅π΅π΅π΅
Similar questions: