WGU E010 FOUNDATIONS OF
PROGRAMMING (PYTHON) OBJECTIVE
ASSESSMENT | OA V3| 100 PRACTICE
QUESTIONS AND ANSWERS | 2026 STUDY
GUIDE | 100% CORRECT.
CORE DOMAINS
Python Syntax, Variables, and Data Types
Operators, Expressions, and Precedence
Control Flow: Conditionals and Branching
Loops and Iteration Patterns
Functions, Scope, and Return Values
Data Structures: Lists, Tuples, Dictionaries, Sets
String Manipulation and Slicing
Debugging, Exceptions, and Problem-Solving
INTRODUCTION
The WGU E010 Foundations of Programming (Python) Objective Assessment
evaluates competency in writing, tracing, and debugging foundational Python
programs. The exam assesses syntax fluency, data type manipulation, control
structure implementation, and functional code design. Questions utilize
multiple-choice and code-tracing formats requiring accurate prediction of
program output and identification of valid Python constructs. Emphasis is
placed on applying core programming concepts to practical coding scenarios
,and developing logical problem-solving skills essential for entry-level software
development and automation tasks.
SECTION ONE: QUESTIONS 1–100
1. Which of the following is the correct way to output the string "Hello,
World!" to the console in Python?
A. printf("Hello, World!")
B. console.log("Hello, World!")
C. print("Hello, World!")
D. echo "Hello, World!"
RATIONALE: The built-in print() function is Python’s standard method
for displaying output to the console. The other options represent syntax from
C, JavaScript, and shell scripting, respectively.
2. Which of the following is a valid variable name in Python?
A. 2nd_place
B. my-var
C. my_var
D. class
RATIONALE: Python variable names must begin with a letter or
underscore, cannot contain hyphens, and cannot be reserved keywords such
as class. The name my_var satisfies all naming rules.
3. What is the data type of the value 3.14 in Python?
,A. int
B. float
C. string
D. boolean
RATIONALE: Numbers containing a decimal point are classified as float
(floating-point) type in Python, regardless of whether they represent whole
numbers.
4. What is the output of print(type(10))?
A. <class 'int'>
B. int
C. 'int'
D. <class 'float'>
RATIONALE: The type() function returns the type object of its argument.
When printed, an integer returns <class 'int'>, including the angle brackets
and quotes.
5. What is the output of print(type())?
A. <class 'int'>
B. <class 'float'>
C. <class 'double'>
D. <class 'str'>
, RATIONALE: In Python 3, the division operator / always performs true
division and returns a float, even when the result is a whole number. Thus, 10
/ 2 yields 5.0.
6. What will the following code output? print(3 + 2 * 4)
A. 20
B. 14
C. 11
D. 24
RATIONALE: Python follows standard mathematical operator
precedence. Multiplication (*) is evaluated before addition (+). Therefore, 2 *
4 equals 8, and 3 + 8 equals 11.
7. What is the result of bool([]) in Python?
A. True
B. False
C. None
D. Error
RATIONALE: Empty containers, including empty lists, dictionaries, sets,
tuples, and strings, evaluate to False in a boolean context. Non-empty
containers evaluate to True.
8. Which of the following is NOT a valid way to create a string in
Python?
A. "hello"
PROGRAMMING (PYTHON) OBJECTIVE
ASSESSMENT | OA V3| 100 PRACTICE
QUESTIONS AND ANSWERS | 2026 STUDY
GUIDE | 100% CORRECT.
CORE DOMAINS
Python Syntax, Variables, and Data Types
Operators, Expressions, and Precedence
Control Flow: Conditionals and Branching
Loops and Iteration Patterns
Functions, Scope, and Return Values
Data Structures: Lists, Tuples, Dictionaries, Sets
String Manipulation and Slicing
Debugging, Exceptions, and Problem-Solving
INTRODUCTION
The WGU E010 Foundations of Programming (Python) Objective Assessment
evaluates competency in writing, tracing, and debugging foundational Python
programs. The exam assesses syntax fluency, data type manipulation, control
structure implementation, and functional code design. Questions utilize
multiple-choice and code-tracing formats requiring accurate prediction of
program output and identification of valid Python constructs. Emphasis is
placed on applying core programming concepts to practical coding scenarios
,and developing logical problem-solving skills essential for entry-level software
development and automation tasks.
SECTION ONE: QUESTIONS 1–100
1. Which of the following is the correct way to output the string "Hello,
World!" to the console in Python?
A. printf("Hello, World!")
B. console.log("Hello, World!")
C. print("Hello, World!")
D. echo "Hello, World!"
RATIONALE: The built-in print() function is Python’s standard method
for displaying output to the console. The other options represent syntax from
C, JavaScript, and shell scripting, respectively.
2. Which of the following is a valid variable name in Python?
A. 2nd_place
B. my-var
C. my_var
D. class
RATIONALE: Python variable names must begin with a letter or
underscore, cannot contain hyphens, and cannot be reserved keywords such
as class. The name my_var satisfies all naming rules.
3. What is the data type of the value 3.14 in Python?
,A. int
B. float
C. string
D. boolean
RATIONALE: Numbers containing a decimal point are classified as float
(floating-point) type in Python, regardless of whether they represent whole
numbers.
4. What is the output of print(type(10))?
A. <class 'int'>
B. int
C. 'int'
D. <class 'float'>
RATIONALE: The type() function returns the type object of its argument.
When printed, an integer returns <class 'int'>, including the angle brackets
and quotes.
5. What is the output of print(type())?
A. <class 'int'>
B. <class 'float'>
C. <class 'double'>
D. <class 'str'>
, RATIONALE: In Python 3, the division operator / always performs true
division and returns a float, even when the result is a whole number. Thus, 10
/ 2 yields 5.0.
6. What will the following code output? print(3 + 2 * 4)
A. 20
B. 14
C. 11
D. 24
RATIONALE: Python follows standard mathematical operator
precedence. Multiplication (*) is evaluated before addition (+). Therefore, 2 *
4 equals 8, and 3 + 8 equals 11.
7. What is the result of bool([]) in Python?
A. True
B. False
C. None
D. Error
RATIONALE: Empty containers, including empty lists, dictionaries, sets,
tuples, and strings, evaluate to False in a boolean context. Non-empty
containers evaluate to True.
8. Which of the following is NOT a valid way to create a string in
Python?
A. "hello"