The Walrus Operator: Python's Assignment Expressions Quiz

Interactive Quiz ⋅ 8 Questions
By Geir Arne Hjelle

In this quiz, you’ll test your understanding of the Python Walrus Operator. This operator, used for assignment expressions, was introduced in Python 3.8 and can be used to assign values to variables as part of an expression.

The quiz contains 8 questions and there is no time limit. You’ll get 1 point for each correct answer. At the end of the quiz, you’ll receive a total score. The maximum score is 100%. Good luck!

Related Resources

Course

Python Assignment Expressions and Using the Walrus Operator

In this course, you'll learn about assignment expressions and the walrus operator. The biggest change in Python 3.8 was the inclusion of the := operator, which you can use to assign variables in the middle of expressions. You'll see several examples of how to take advantage of this new feature.

intermediate best-practices

Tutorial

The Walrus Operator: Python's Assignment Expressions

In this tutorial, you'll learn about assignment expressions and the walrus operator. The biggest change back in Python 3.8 was the inclusion of the := operator, which you can use to assign variables in the middle of expressions. You'll see several examples of how to take advantage of this feature.

intermediate best-practices