ASSESSMENT OA V AND CORRECT ANSWERS (VERIFIED ANSWERS)
PLUS RATIONALES Q&A INSTANT DOWNLOAD PDF.
50 QUESTIONS
TABLE OF CONTENTS
# TOPIC
1 Trace and predict the exact runtime behavior of Python code involving mutability, aliasing, scope, and
control flow
2 Select and apply appropriate data structures, comprehensions, and built-in methods to transform and
aggregate data
3 Diagnose and correct defects in functions, file handling, exception handling, and class definitions
4 WGU E010 FOUNDATIONS OF PROGRAMMING
5 PYTHON
6 OBJECTIVE ASSESSMENT OA V AND CORRECT ANSWERS
7 VERIFIED ANSWERS
8 PLUS RATIONALES Q&A INSTANT DOWNLOAD PDF.
9 Foundations of Computer Science / Programming Fundamentals (Python)
10 Applied Computer Science / Programming Fundamentals (Python)
11 Advanced Computer Science / Programming Fundamentals (Python)
12 Computer Science / Programming Fundamentals (Python) Review
ABSTRACT
Page 1
,This study document brings together 50 carefully worded exam questions drawn from WGU E010
FOUNDATIONS OF PROGRAMMING (PYTHON) OBJECTIVE ASSESSMENT OA V AND
CORRECT ANSWERS (VERIFIED ANSWERS) PLUS RATIONALES Q&A INSTANT DOWNLOAD
PDF., with the strongest emphasis placed on Trace and predict the exact runtime behavior of
Python code involving mutability, aliasing, scope, and control flow, Select and apply appropriate
data structures, comprehensions, and built-in methods to transform and aggregate data, Diagnose
and correct defects in functions, file handling, exception handling and and class definitions. Every
item follows the wording style and level of reasoning you meet in the real paper, and each one is
paired with a clear rationale so the correct choice is never a guess. Work through the set at your
own pace, mark the questions that slow you down, then come back to them until the reasoning
feels automatic. Learners who revise this way walk into the exam room recognising the pattern
behind the questions instead of meeting them for the first time. Keep going - steady, honest
practice is what turns a difficult paper into a comfortable pass.
Q1 TRACE AND PREDICT THE EXACT RUNTIME BEHAVIOR OF PYTHON CODE INVOLVING
MUTABILITY, ALIASING, SCOPE, AND CONTROL FLOW
Consider: a = [[0]*2]*2; a[0][0] = 9. What is the value of a?
A. [[9, 0], [0, 0]]
B. [[9, 0], [9, 0]] CORRECT
C. [[9, 9], [0, 0]]
D. [[0, 0], [0, 0]]
RATIONALE: The outer multiplication replicates the same inner list object twice, so both rows
alias one list; mutating a[0][0] is visible through a[1]. Option A assumes independent inner lists
(true only if built via a comprehension), C misplaces the aliasing, and D ignores mutation entirely.
Page 2
, Q2 TRACE AND PREDICT THE EXACT RUNTIME BEHAVIOR OF PYTHON CODE INVOLVING
MUTABILITY, ALIASING, SCOPE, AND CONTROL FLOW
def f(x, acc=[]): acc.append(x); return acc. After f(1); f(2); f(3), what does the third
call return?
A. [3]
B. [1, 2, 3] CORRECT
C. [2, 3]
D. Raises TypeError
RATIONALE: Default arguments are evaluated once at definition time, so the same list object
persists across calls and accumulates 1, 2, 3. Option A assumes a fresh list per call, C misorders
the accumulation, and D is false because list mutation is legal.
Q3 TRACE AND PREDICT THE EXACT RUNTIME BEHAVIOR OF PYTHON CODE INVOLVING
MUTABILITY, ALIASING, SCOPE, AND CONTROL FLOW
nums = [3, 1, 4, 1, 5]; result = [n for n in nums if n > 1]. What is result?
A. [3, 4, 5] CORRECT
B. [3, 1, 4, 1, 5]
C. [1, 1]
D. [3, 4, 5, 1]
RATIONALE: The comprehension retains only elements strictly greater than 1, preserving order:
3, 4, 5. Option C inverts the condition, B omits filtering, and D incorrectly retains a '1' that fails the
predicate.
Page 3