Week 4 — Module Framing · Booleans & Conditionals
Course: Introduction to Computer Science — CS1 / Programming Fundamentals in Python (CSCI 1101) · Silver Oak University (fictional sample) · Prof. Okafor
Module: Week 4 of 16 · Fall 2026 · in-person, two 75-minute coding-along studio sessions
Objective covered: Objective 3 — Use Boolean logic and conditionals — comparison and logical operators, truth tables, and if/elif/else — to make programs decide.
This file holds two pieces: (A) the Module 4 Overview page ("Start Here") and (B) the Welcome Announcement that drips out when the module opens. Dates below assume a Tuesday/Thursday pattern with Week 4 meeting Tue Sep 22 and Thu Sep 24, a Coding Lab that same week, and end-of-week work due Sunday Sep 27, 11:59 p.m. Adjust the day-of-week and times to match your section.
(A) Module 4 Overview — Start Here
Welcome to Week 4: Booleans & Conditionals
This is your home base for the week. Read it first, then work the checklist below from top to bottom. Everything you need is linked inside the module.
For three weeks your programs have run straight through, top to bottom — every line, every time. This week they start to decide. You'll meet the bool type (True and False), the comparison operators that produce it (==, !=, <, >, <=, >=), the logical operators (and, or, not) that combine conditions, and the if / elif / else statement that uses all of it to pick which code runs. By Friday you'll have written a small program that gives different answers for different inputs — a price by age, a grade by score — and you'll have met the single most famous beginner trap in the language: = versus ==. As always, the habit that carries the week: don't guess which branch runs — run it and watch.
The week's big question
"How does a program make a decision — and how do you control exactly which code runs?"
By Friday you'll be able to evaluate a Boolean expression (and predict its True/False value), read a truth table for and/or/not, write an if/elif/else that routes to the right branch, and spot the =-where-==-belongs bug on sight.
By the end of this week, you can…
Use this as a checklist. If you can do all four, you're ready for the quiz.
- [ ] Evaluate Boolean expressions — predict the
True/Falseresult of comparisons (==,!=,<,>,<=,>=) and logical combinations (and,or,not), then run them to confirm. - [ ] Read and build a truth table — know what
and,or, andnotdo for every combination of inputs, and the precedence ordernot→and→or. - [ ] Write an
if/elif/else— route a program to exactly one branch, and trace which branch runs for a given input. - [ ] Spot the
=vs==bug — know thatif x = 5:is aSyntaxErrorandif x == 5:correctly compares, and fix an out-of-orderelifchain.
What's due this week, and when
Work these in order — each one gets you ready for the next.
| # | Do this | Type | Due |
|---|---|---|---|
| 1 | Read the week's readings + watch the linked videos | Read / watch (ungraded prep) | Before Thu Sep 24 |
| 2 | Skim the slides (Deck 4) and the Week 4 lecture outline | Prep (ungraded) | Alongside class |
| 3 | Lecture Tutorial 4 — work through Booleans, truth tables, and if/elif/else with one approved chatbot (Gemini, Claude, or ChatGPT), then submit the conversation share link |
Lecture Tutorial · graded (5% group) | Sun Sep 27, 11:59 p.m. |
| 4 | Practice exercises — low-stakes reps to lock in the ideas | Practice · ungraded | Sun Sep 27 (recommended) |
| 5 | Coding Lab 4 — "Decisions, Decisions" — write a small if/elif/else program, fill in a predict-then-run truth table, fix a =-vs-== bug, then catch the AI getting and/or precedence or a boundary wrong |
Coding Lab · graded (Coding Labs, 15% group) · 50 pts | Sun Sep 27, 11:59 p.m. |
| 6 | Quiz 4 — covers comparison & logical operators, truth tables, which-branch-runs, and the =-vs-== debug |
Quiz · graded (Quizzes, 10% group) | Sun Sep 27, 11:59 p.m. |
| 7 | Discussion 4 — "When Code Decides About People" — weigh the benefits and risks of automated decisions (loan approval, content moderation, résumé filtering) in a dialogue with one approved chatbot, then post the AI summary + your chat link and reply to two classmates | Discussion · graded (Discussions, 10% group) | Initial post Fri Sep 25; replies Sun Sep 27 |
| 8 | Assignment 4 — "Programs That Decide" — write an if/elif/else classifier, evaluate Boolean expressions, trace a branch, and fix a bug, coached and scored by one approved chatbot |
Assignment · graded (Assignments, 15% group) · 100 pts | Sun Sep 27, 11:59 p.m. |
Heads-up on the AI tools: you'll use a chatbot as a pair-programmer to draft and explain — and then you check its work by running the code. Chatbots are famous for getting and/or precedence wrong, or flipping a boundary (>= vs >), and stating it with total confidence. Catching that — by running the code and reading the real output — is the point, in the tutorial, the assignment, and the lab.
How to succeed this week
- Run every Boolean. When you're unsure whether
True and not FalseisTrue, don't argue with yourself — typeprint(True and not False)and run it. The interpreter is the referee. - Two tiny hooks to memorize. "
=puts a value in;==asks a question." And "notbeforeandbeforeor— that's the precedence order, every time." - Trace the branch. Before you run an
if/elif/else, point at the exact line you think will execute. Then run it. Python checks the conditions top to bottom and takes the first one that's true — and skips the rest. - Order your
elifs from most specific to least. A condition likescore >= 60placed first will swallow a 95 beforescore >= 90ever gets a look. Branch order is a logic bug, not a syntax error — the program runs, it's just wrong. - Treat the chatbot as a smart intern, not an oracle. It will confidently mis-rank
andandor, or say a boundary value lands in the wrong branch. You run the code and catch it. That habit is the whole semester in miniature.
You don't need any setup for this week — the Python environment runs in your browser, nothing to install. Come to class ready to make your programs choose. See you Tuesday.
(B) Welcome Announcement — Module 4
Release setting: post on the module's start day (offset = 0 days), i.e., Tue Sep 22, 2026 — not before. If your platform won't preserve the scheduled date on import, post this as a draft labeled "Release: Tue Sep 22."
Subject: Week 4 — this is the week your programs start to decide 🔀
Hi everyone,
For three weeks our programs have done exactly one thing: run straight through, top to bottom, the same way every time. This week they learn to choose. We meet True and False (the bool type), the comparison operators that produce them (==, !=, <, >, <=, >=), the logical operators that combine them (and, or, not), and the if / elif / else statement that decides which code actually runs.
This week — Booleans & Conditionals — we tackle the big question: How does a program make a decision, and how do you control exactly which code runs? By Friday you'll write a program that gives different answers for different inputs — a ticket price by age, a letter grade by score — and you'll meet the single most famous trap in the language.
Three things not to miss:
1. Lecture Tutorial 4 — work through Booleans, truth tables, and if/elif/else with one approved chatbot (Gemini, Claude, or ChatGPT) and submit the share link. Due Sun Sep 27.
2. Coding Lab 4 ("Decisions, Decisions"), Quiz 4, Discussion 4, and Assignment 4 also close Sun Sep 27 — the lab is where you write the branching code and fill in a truth table by running it, so start early.
3. Open the Start Here page first — it lays out everything in order with due dates.
One trap to circle on day one: = and == are not the same. A single = stores a value (x = 5); a double == asks a question (x == 5 → True or False). Put a single = inside an if and Python stops with a SyntaxError before it runs a line. We'll meet it head-on in class — and you'll be glad we did.
And the discussion this week is a big one: when programs make decisions about people — who gets a loan, whose post gets removed, whose résumé gets read — what do we gain, what do we risk, and who's accountable when the automated call is wrong? Come with an open mind; there are real arguments on more than one side.
Bring your curiosity (and a willingness to be wrong about whether not (3 > 2) is True) to class on Tuesday.
See you soon,
Prof. Okafor
~ Prof. Okafor's edition · Fall 2026 · built with thecoursemaker.com