Online Access Free Foundations-of-Programming-Python Practice Test
| Exam Code: | Foundations-of-Programming-Python |
| Exam Name: | Foundations of Programming (Python) - E010 JIV1 |
| Certification Provider: | WGU |
| Free Question Number: | 62 |
| Posted: | Aug 15, 2026 |
What distinguishes a terminal-based Python environment from other development environments?
A program needs to display only positive, non-zero numbers from a list containing a mixture of integer and decimal values. Which conditional statement should be placed inside the loop?
Write a complete function calculate_discount(price, discount_percent) that calculates and returns the final price after applying a discount percentage.
For example, calculate_discount(75, 20) should return 60.0.
def calculate_discount(price, discount_percent):
# TODO: Calculate and return the final price after discount
pass
What must be consistent within a Python code block for the code to run without syntax errors?