Week 5 Unit 3: Self-test
Last updated:
(05. April 2024)
Question 1
Which of the following statements about parameters and functions are correct?
Note: There are 3 correct answers to this question.
Input parameters to functions must be of the primitive data type.
❌Functions in Python can have zero, one, or several parameters.
✅The data type of the parameters must be declared in the definition statement of the function.
❌The number of return values does not depend on the number of input parameters.
✅The naming rules for parameters are the same as the naming rules for variables.
✅Question 2
What is the outcome of the following program?




