Programming Labs — the five-level collection
How to use this section: labs are where concepts become skill. Each level names the units it requires — do not start a lab whose concepts you haven’t met (the syllabus is the map). Attempt each lab from its task list alone; the complete solution and explanation come after your attempt, and the testing checklist is the referee.
The five levels
| Level | Units first | Labs | The territory |
|---|---|---|---|
| 1 — Beginner | 01–04 | 8 | first programs, I/O, arithmetic, decisions — no loops yet |
| 2 — Basic | 04–06 | 8 | menus, validation, counted and sentinel loops, patterns |
| 3 — Intermediate | 07–09 | 8 | functions and decomposition, arrays and vector, collection statistics |
| 4 — Advanced | 10–15 | 10 | algorithms, strings, files, pointers, records, classes |
| 5 — Integrated | 12–16 | 8 | multi-concept systems — the capstone rehearsal tier |
The fifteen-part shape
Every lab below carries the same fifteen parts — this is the contract:
- Scenario — the realistic situation and who the software serves
- Problem statement — the precise task in one paragraph
- Learning objectives — what you can do afterwards
- Requirements — numbered, testable statements
- Input — the exact input contract
- Output — the exact output contract
- Constraints — the limits and honesty rules (ranges, error handling)
- Example — one worked run
- Test cases — normal, boundary, invalid (the Debugging module’s three families)
- Student tasks — the build order
- Hints — graded, one at a time
- Extension challenges — for after the checklist passes
- Complete solution — full, compilable code
- Solution explanation — why, not just what
- Testing checklist — the pass/fail list before you move on
The protocol
- Read the whole lab before typing anything. Requirements and constraints are the contract.
- Build in task order — every task ends in a running program. The tasks are compiled, not aspirational.
- Test with the given cases before inventing your own. Then invent your own — the boundary rows are where marks and bugs live.
- Open the solution only after the checklist is green — or after two honest failed attempts (then diff your version against it; the diff is the lesson).
- Log the bugs you hit in the bug journal — the Debugging Challenge Lab’s Phase 3 discipline applies course-wide.
The progress checklist
- Level 1: L1-01 ☐ · L1-02 ☐ · L1-03 ☐ · L1-04 ☐ · L1-05 ☐ · L1-06 ☐ · L1-07 ☐ · L1-08 ☐
- Level 2: L2-09 ☐ · L2-10 ☐ · L2-11 ☐ · L2-12 ☐ · L2-13 ☐ · L2-14 ☐ · L2-15 ☐ · L2-16 ☐
- Level 3: L3-17 ☐ · L3-18 ☐ · L3-19 ☐ · L3-20 ☐ · L3-21 ☐ · L3-22 ☐ · L3-23 ☐ · L3-24 ☐
- Level 4: L4-25 ☐ · L4-26 ☐ · L4-27 ☐ · L4-28 ☐ · L4-29 ☐ · L4-30 ☐ · L4-31 ☐ · L4-32 ☐ · L4-33 ☐ · L4-34 ☐
- Level 5: L5-35 ☐ · L5-36 ☐ · L5-37 ☐ · L5-38 ☐ · L5-39 ☐ · L5-40 ☐ · L5-41 ☐ · L5-42 ☐
Level index
| # | Lab | Context | Core concepts |
|---|---|---|---|
| Level 1 — Beginner | |||
| L1-01 | The Canteen Receipt | billing | cout, arithmetic |
| L1-02 | Student ID Card | student systems | cout, string output |
| L1-03 | Temperature Desk | utility conversion | cin, arithmetic |
| L1-04 | Market Money | small business | arithmetic, formatting |
| L1-05 | Cinema Pass | billing rules | if/else-if |
| L1-06 | Load Shedding Checker | utility schedule | switch |
| L1-07 | Admission Desk | student systems | compound conditions |
| L1-08 | Word Wizard | text analysis | getline, char counting |
| Level 2 — Basic | |||
| L2-09 | The Menu Canteen | billing | do-while menus |
| L2-10 | Fee Counter | student fees | sentinel sums |
| L2-11 | Utility Bill Desk | utility calculation | tiered loops + validation |
| L2-12 | Quiz Machine | student practice | counters, do-while |
| L2-13 | Number Properties Desk | algorithmic | digit loops |
| L2-14 | Pattern Press | pattern printing | nested loops |
| L2-15 | Stock Take | inventory | counted input loops |
| L2-16 | Guess Desk | algorithmic | loops + decisions |
| Level 3 — Intermediate | |||
| L3-17 | Marks Analyzer | student systems | vectors, statistics |
| L3-18 | Payroll Desk | small business | parallel vectors, functions |
| L3-19 | Temperature Station | data processing | min/max/average over collections |
| L3-20 | Word Frequency Counter | text analysis | parallel arrays, searching |
| L3-21 | Queue Simulator | scheduling | array shifting, simulation |
| L3-22 | Voting Booth | record management | frequency counting, validation |
| L3-23 | Matrix Marks Grid | student systems | 2D arrays |
| L3-24 | Inventory Reorder | inventory | vectors, searching, thresholds |
| Level 4 — Advanced | |||
| L4-25 | The Sorting Desk | algorithmic | sorting algorithms, comparisons |
| L4-26 | Dictionary Lookups | text analysis | binary search, strings |
| L4-27 | Recursion Workshop | algorithmic | recursion, call stack |
| L4-28 | Text Toolkit Pro | text analysis | string algorithms, cctype |
| L4-29 | The Persistent Gradebook | student systems | file I/O, CSV |
| L4-30 | The Library Ledger | library systems | file records, search |
| L4-31 | The Safe Ledger | record management | pointers, dynamic arrays |
| L4-32 | The Student Registry | student systems | structs, records |
| L4-33 | The Fee Account Family | banking simulation | classes, encapsulation |
| L4-34 | The Course Catalogue | student systems | vectors of objects, design |
| Level 5 — Integrated | |||
| L5-35 | The Expense Tracker Pro | small business | files + functions + validation |
| L5-36 | The Bank Simulation | banking simulation | classes + files + vectors |
| L5-37 | The Library Management System | library systems | classes + files + search |
| L5-38 | The Scheduling Desk | scheduling | sorting + structs + files |
| L5-39 | The Survey Analyzer | data processing | files + statistics + validation |
| L5-40 | The Inventory Control System | inventory | structs + files + reports |
| L5-41 | The Contact Book | record management | search + sort + files |
| L5-42 | The Result Processing System | student systems | everything — the capstone rehearsal |
— Engr. Dr. Muhammad Nadeem Majeed, Professor, Department of Data Science (PUCIT), University of the Punjab, Lahore · About the instructor