The following statement:
assert var == 0
- has no effect
- will stop the program when var != 0
- will stop the program when var == 0
- is erroneous
Explanation: Remember that the assert keyword tests if a condition is true. If it is not, the program will raise an AssertionError.
More Questions: Python Essentials 2 – Module 2 Test
More Questions: Python Essentials 2 (PE2) Course Final Test
Please login or Register to submit your answer