Module 3 Graded Quiz: Python Programming Fundamentals :Python for Data Science, AI & Development (Applied Data Science Specialization) Answers 2025
Question 1 — Output of code
-
❌ Go Stop
-
✅ Stop Mike
-
❌ Go Mike
-
❌ Mike
Question 2 — Purpose of comparison operators
-
❌ To convert numeric variables to string representations
-
✅ To evaluate expressions and assign the resulting Boolean values to variables
-
❌ To initialize variables with default values
-
❌ To perform mathematical operations
Question 3 — What ends a while loop?
-
✅ The evaluation of its conditional expression to False
-
❌ Presence of a print statement
-
❌ Number of statements in the loop
-
❌ Executes exactly five times
Question 4 — Output of class code
Correct output:
x= A y= B
-
❌ y=B
-
❌ x=A
-
❌ x=y=
-
✅ x=A y=B
Question 5 — Output of enumerate loop
-
✅ 0 AA 1 BB 2 CC
-
❌ 0 A 1 B 2 C
-
❌ 0 A 2 B 4 C
-
❌ 1 AA 2 BB 3 CC
Question 6 — Result of object mutation
-
❌ x= Denver y= Boston
-
❌ x= Boston y= Chicago
-
✅ x= Boston y= Denver
-
❌ x= Denver y= Denver
Question 7 — Range validation
32 is between 20 and 40.
-
❌ “Invalid”
-
✅ “Valid”
-
❌ False
-
❌ None
Question 8 — Output of do()
Returns 1 + 100 = 101.
-
❌ Product of local variable and parameter
-
❌ Sum of global variable and parameter
-
✅ Sum of local variable and parameter
-
❌ Value of global variable only
Question 9 — Efficient function to add two numbers
-
❌ Built-in sum with tuple conversion
-
❌ Built-in sum with individual parameters
-
✅ Direct return of parameter summation
-
❌ Intermediate variable assignment
Question 10 — Why multiple except statements?
-
❌ Ensure catching the error for program termination
-
✅ To determine the type of error thrown and its location within the program
-
❌ Skip specific sections of code
-
❌ Not necessary
If you want, I can prepare the 🧾 Summary Table for all answers.