Course Schedule
Guide roadmap and active milestone tracking. Click the circle next to any week number to toggle completion!
| Wk | Topic Details | Due State | Resources & Solutions |
|---|---|---|---|
| 1 | Intro to terminal & local Python coordination | Completed | — |
| 2 | Built-in types: String, Integer, Float, list, tuple |
Completed | — |
| 3 | Built-in types: dict, Functions: def, *args, **kwargs |
Completed | — |
| 4 | Conditionals & Branching logic: if, elif, else |
Active Week | 📝 HW1 released |
| 5 | Loops & Iteration: for and while loops |
HW1 due | — |
| 6 | Nested loops, break, continue, enumerate |
— | — |
| 7 | Comprehensions: List, dictionary, and set structures | — | 📝 HW2 released |
| 8 | File I/O: open and with, Exceptions: try/except |
HW2 due | — |
| 9 | Command-line Arguments: sys.argv, argparse |
Midterm | |
| 10 | Scripts, Modules & Packages: import, as, __main__ |
— | 📝 HW3 released |
| 11 | General Programming: Language model backend | HW3 due | 📝 HW4 released |
| 12 | Object Oriented Programming (OOP) | HW4 due | 📝 HW4.5 released |
| 13 | General Programming: business application program 2 | HW4.5 due | 📝 HW5 released |
| 14 | Advanced logical optimization & trace debugging | — | — |
| 15 | Comprehensive course review & trace practice | HW5 due | — |
| 16 | Final exams / business system submissions | — |
Upcoming Exam Review
Review solutions below or click keys inline inside the Course Schedule table to expand them instantly.
Exam Keys
Collapsible detailed answer sets.
Practice Final
PDFPractice Final Key
1) Multiple Choice
- 1.1 # 2.
3 - 1.2 # 1.
[n**2 for n in nums] - 1.3 # 1. It automatically closes the file when the block is done
- 1.4 # 2. Python runs the matching
exceptblock - 1.5 # 2.
import math - 1.6 # 2. Skips iteration
- 1.7 # 4.
5 - 1.8 # 1.
x > 10 and x < 20
2) True/False
- 2.1 True
- 2.2 True
- 2.3 True
- 2.4 True
- 2.5 True
- 2.6 True
- 2.7 False
- 2.8 False
3) Code Tracing
- 3.1
[4, 8] - 3.2
2 - 3.3
15 - 3.4
60
4) Open Ended
4.1
def positiveSquares(L):
return [x**2 for x in L if x > 0]
4.2
def countLines(filename):
count = 0
with open(filename) as f:
for line in f:
count += 1
return count
4.3
def safeInt(s):
try:
return int(s)
except ValueError:
return None
Spring 2026 Midterm
PDFSpring 2026 Midterm Key
1) Multiple Choice
- 1.1 # 2.
4 - 1.2 # 1.
ababab - 1.3 # 2.
[1,2,3] - 1.4 # 2.
== - 1.5 # 2. Exits loop
- 1.6 # 2.
0,1,2 - 1.7 # 3. Index-value pairs
- 1.8 # 3.
<class 'tuple'>
2) True/False
- 2.1 True
- 2.2 True
- 2.3 False
- 2.4 True
- 2.5 False
- 2.6 False
- 2.7 True
- 2.8 True
3) Code Tracing
- 3.1
1, 2, 3 - 3.2
1, 3, 5 - 3.3
9 - 3.4
10
4) Open-Ended
4.1
def countGreater(L, k):
count = 0
for x in L:
if x > k:
count += 1
return count
4.2
def sumList(L):
total = 0
for x in L:
total += x
return total
4.3
def reverseList(L):
return L[::-1]
Practice Midterm
PDFPractice Midterm Key
1) Multiple Choice
- 1.1 # 3.
5 - 1.2 # 2.
(1,2,3) - 1.3 # 2.
A B C - 1.4 # 3. Membership check
- 1.5 # 3.
while - 1.6 # 2.
4 - 1.7 # 2.
{1:2,3:4} - 1.8 # 3. Skips iteration
2) True/False
- 2.1 True
- 2.2 False
- 2.3 True
- 2.4 True
- 2.5 True
- 2.6 True
- 2.7 True
- 2.8 True
3) Code Tracing
- 3.1
1, 2, 3 - 3.2
10 - 3.3
7 - 3.4
10, 30
4) Open-Ended
4.1
def countOdd(L):
count = 0
for x in L:
if x % 2 == 1:
count += 1
return count
4.2
def maxDiff(L):
return max(L) - min(L)
4.3
def sumIndices(L):
total = 0
for i in range(len(L)):
if i % 2 == 0:
total += L[i]
return total
Fall 2025 Midterm
PDFFall 2025 Midterm Key
1) Multiple Choice
- 1.1 # 1.
set(L) - 1.2 # 3. Reverse
- 1.3 # 1. list comprehension
- 1.4 Index first, value second
- 1.5 # 3.
"a" - 1.6 # 2. Skips remaining
2) True/False
- 2.1 False
- 2.2 True
- 2.3 False
- 2.4 True
3) Short Traces
- 3.1
1 - 3.2
[1, 2, 3, [4, 5]] - 3.3
5 - 3.4
4
4) Open-Ended
4.1
def elements_at_odd_indices(L):
return [L[i] for i in range(len(L)) if i % 2 == 1]
4.2
total = 0
with open("nums.txt") as f:
lines = f.readlines()
for line in lines:
total += int(line)
avg = total / len(lines)
print(avg)
4.3
cubes = [n**3 for n in nums]