Free sample · no account needed

Try 5 Python questions

Pick an answer for each question, then check them all at once. You will see the correct answers and explanations.

Question 1 of 5 · Advanced Python Concepts

What does {'a': 1, 'b': 2}.get('c', 0) return?

print({'a': 1, 'b': 2}.get('c', 0))
Question 2 of 5 · Python Functions

What is a default parameter?

Question 3 of 5 · Python Coding Challenges

What does 'python'[-1] return?

print('python'[-1])
Question 4 of 5 · Python Collections

What does list(range(2, 6)) return?

print(list(range(2, 6)))
Question