Programming & Product Design

Learn to design algorithms, write Python code, and apply the MYP Design Cycle. Understand how CAD, CAM, systems thinking, and sustainable design principles connect to create effective solutions.

What You'll Learn

  • Design algorithms using pseudocode and flowcharts
  • Write Python programs using variables, data types, conditionals, loops, and functions
  • Debug and test programs systematically
  • Apply all four stages of the MYP Design Cycle
  • Understand the role of CAD and CAM in modern design
  • Apply systems thinking to understand how design components interact
  • Incorporate sustainable design principles into your work
  • Write a design brief and evaluate against specifications

IB Assessment Focus

Criterion A — Inquiring & Analysing: Research and justify the need; analyse existing products; develop a design brief.

Criterion B — Developing Ideas: Develop a specification; generate and evaluate multiple ideas; justify the best solution.

Criterion C — Creating the Solution: Create the solution; document and justify any changes to the plan.

Criterion D — Evaluating: Evaluate the product against the specification; test with users; identify improvements.

Key Vocabulary

TermDefinition
AlgorithmA step-by-step set of instructions to solve a problem
PseudocodeAn informal, human-readable description of an algorithm's logic (not real code)
FlowchartA visual diagram showing the steps and decisions in an algorithm
VariableA named storage location in a program that holds a value
LoopA programming structure that repeats code (for loop, while loop)
ConditionalCode that executes different actions based on a condition (if/else)
FunctionA reusable block of code that performs a specific task
DebuggingThe process of finding and fixing errors (bugs) in a program

Algorithm Design

An algorithm is the plan for your program — you design the logic before writing code. Two key tools for representing algorithms are pseudocode and flowcharts.

Pseudocode

Pseudocode is an informal, structured way to describe an algorithm using plain language. It is not a programming language, but it follows a logical structure that can be easily translated into code.

Example: Calculate the area of a rectangle
INPUT length
INPUT width
SET area = length * width
OUTPUT "The area is " + area
Example: Check if a student passes or fails
INPUT score
IF score >= 50 THEN
    OUTPUT "Pass"
ELSE
    OUTPUT "Fail"
END IF

Flowcharts

Flowcharts use standard symbols to visually represent the steps and decisions in an algorithm:

SymbolShapeMeaning
OvalRounded rectangleStart / End (terminator)
RectangleBoxProcess (calculation, assignment)
DiamondDiamond shapeDecision (yes/no question)
ParallelogramSlanted rectangleInput / Output
ArrowLine with arrowheadFlow direction
Key Point: Always design your algorithm before writing code. Pseudocode and flowcharts help you plan the logic, identify edge cases, and reduce errors. This is especially important for Criterion B (Developing Ideas).

Python Programming Basics

Python is a beginner-friendly programming language used in MYP Design. Learn the core building blocks: variables, data types, conditionals, loops, and functions.

Variables & Data Types

A variable stores a value that can be used and changed throughout a program. Python has several data types:

Data TypeDescriptionExample
String (str)Text, enclosed in quotes"Hello", 'IB Student'
Integer (int)Whole number42, -7, 0
FloatDecimal number3.14, -0.5
Boolean (bool)True or FalseTrue, False
# Creating variables
name = "Lukas"        # String
age = 14              # Integer
height = 1.72         # Float
is_student = True     # Boolean

# Getting user input
user_name = input("Enter your name: ")
user_age = int(input("Enter your age: "))  # Convert input to integer

Conditional Statements (if/else)

Conditionals let your program make decisions based on conditions. Python uses if, elif (else if), and else.

# Simple if/else
if age >= 18:
    print("You are an adult")
else:
    print("You are a minor")

# Multiple conditions with elif
score = 85
if score >= 90:
    print("Grade: A")
elif score >= 80:
    print("Grade: B")
elif score >= 70:
    print("Grade: C")
else:
    print("Grade: below C")

Loops

Loops repeat a block of code. Python has two types:

For loop — repeats a set number of times:
# Print numbers 0 to 4
for i in range(5):
    print(i)        # Output: 0, 1, 2, 3, 4

# Print each item in a list
fruits = ["apple", "banana", "cherry"]
for fruit in fruits:
    print(fruit)
While loop — repeats while a condition is true:
# Count down from 5
count = 5
while count > 0:
    print(count)
    count = count - 1   # Don't forget to change the variable!
print("Go!")

Functions

A function is a reusable block of code that performs a specific task. Functions help organise your program, reduce repetition, and make code easier to read and debug.

# Defining a function
def greet(name):
    print("Hello, " + name + "!")

# Calling the function
greet("Lukas")      # Output: Hello, Lukas!
greet("Teacher")    # Output: Hello, Teacher!

# Function with a return value
def calculate_area(length, width):
    area = length * width
    return area

result = calculate_area(5, 3)
print(result)       # Output: 15
Common Mistakes: (1) Forgetting the colon : after if, for, while, or def statements. (2) Incorrect indentation — Python uses indentation to define code blocks. (3) Infinite while loops — always update the loop variable. (4) Using = (assignment) instead of == (comparison) in conditions.

The MYP Design Cycle

The Design Cycle is a structured process for developing solutions. In MYP Design, every project follows these four stages, which directly align with the four assessment criteria.

The Four Stages

StageCriterionWhat You DoKey Outputs
1. Inquire & AnalyseCriterion AIdentify the problem; research the context; analyse existing products; write a design briefResearch notes, product analysis, design brief
2. Develop IdeasCriterion BWrite a design specification; generate multiple ideas; evaluate and justify the chosen designSpecification, sketches/prototypes, justified selection
3. Create the SolutionCriterion CBuild/code the final product; document changes and justify them; follow the planFinished product, development log with justifications
4. EvaluateCriterion DTest the product against the specification; gather user feedback; identify improvementsTest results, evaluation report, improvement suggestions

Writing a Design Brief

A design brief is a short, clear statement that outlines the problem you are solving and for whom. It should include:

  • The problem or need: What issue have you identified?
  • The client or target audience: Who will use the solution?
  • The context: Where and when will it be used?
  • Constraints: Budget, time, materials, or other limitations
  • The proposed solution type: What kind of product will you create?

Example: "I will design a Python quiz program for Grade 7 students to help them revise key vocabulary for their Science exam. The program must be easy to use, provide immediate feedback, and track the user's score."

Design Specification

The specification is a list of measurable criteria your product must meet. Each point should be testable so you can evaluate your product against it in Stage 4.

Example specification for a quiz program:
  1. Must include at least 10 questions
  2. Must display the correct answer when the user gets it wrong
  3. Must track and display a final score
  4. Must be easy for a Grade 7 student to navigate without help
  5. Must run without errors (no crashes)
  6. Must use appropriate vocabulary for the target audience
Critical Rule: In Criterion C (Creating the Solution), you must document any changes to your plan and justify why you made them. Simply making changes without documenting them will result in lost marks. Changes are expected — what matters is that you explain and justify them.

CAD, CAM & Sustainable Design

Modern design uses digital tools and must consider environmental impact. Understand how technology and sustainability principles shape the design process.

CAD — Computer-Aided Design

What it is: Software used to create precise 2D drawings and 3D models of products digitally before they are manufactured.

Advantages:

  • Designs can be easily modified, shared, and stored
  • Allows precise measurements and dimensions
  • 3D models can be rotated and viewed from any angle
  • Reduces material waste (test designs before building)
  • Can be directly linked to CAM for manufacturing

Examples: Tinkercad, SketchUp, Fusion 360, AutoCAD

CAM — Computer-Aided Manufacturing

What it is: Using computer-controlled machines to manufacture products from CAD designs.

Advantages:

  • High precision and consistency — every product is identical
  • Faster production than manual manufacturing
  • Reduces human error
  • Can produce complex shapes that are difficult to make by hand

Examples: 3D printers, laser cutters, CNC routers, vinyl cutters

Systems Thinking

Systems thinking means understanding how all parts of a system interact and affect each other. In design, changing one component has knock-on effects on others.

Example: Changing a product's material from plastic to bamboo affects:

  • Cost: Bamboo may be more or less expensive
  • Manufacturing: Different tools and processes are needed
  • Weight: The product may be lighter or heavier
  • Durability: Bamboo has different structural properties
  • Environmental impact: Bamboo is renewable and biodegradable
  • Aesthetics: The product will look and feel different

Sustainable Design Principles

Sustainable design considers the environmental impact of a product throughout its entire lifecycle — from material sourcing to manufacturing, use, and disposal.

PrincipleWhat It MeansExample
ReduceUse fewer materials; minimise wasteLightweight packaging, efficient use of material sheets
ReuseDesign products that can be used againRefillable containers, modular components
RecycleUse materials that can be recycled at end of lifeAluminium, glass, certain plastics
Renewable materialsUse materials that can be regrown or replenishedBamboo, wood from managed forests, cotton
Energy efficiencyMinimise energy used in manufacturing and product useLED lighting, efficient motors
DurabilityDesign products to last, reducing the need for replacementQuality construction, timeless design

Debugging, Testing & Evaluation

Testing and evaluation ensure your solution works correctly and meets the design specification. Debugging is a critical skill for any programmer.

Debugging

Debugging is the process of finding and fixing errors (bugs) in your code. There are three main types of errors:

Error TypeWhat It IsExample
Syntax errorBreaking the rules of the programming language; the program won't runMissing colon: if age > 18 instead of if age > 18:
Runtime errorThe program runs but crashes during executionDividing by zero, accessing a list index that doesn't exist
Logic errorThe program runs without crashing but produces the wrong outputUsing + instead of * in an area calculation

Debugging Strategies

  • Read the error message: Python tells you the line number and type of error
  • Use print statements: Print variable values at key points to check they are correct
  • Test with different inputs: Try normal, boundary, and invalid inputs
  • Trace through the code: Follow the logic step by step on paper
  • Comment out sections: Isolate the problem by temporarily removing code

Testing Your Solution

Systematic testing ensures your program handles all types of input correctly:

Test TypePurposeExample (for a quiz accepting scores 0–100)
Normal dataTest with typical, expected inputsScore = 75
Boundary dataTest at the limits of acceptable inputScore = 0, Score = 100, Score = 50 (pass/fail boundary)
Invalid dataTest with inputs that should be rejectedScore = -5, Score = 150, Score = "abc"

Evaluating Against the Specification

In Criterion D, you must evaluate your final product against each point in your design specification:

  1. Test each specification point and record the results (pass/fail with evidence)
  2. Gather user feedback from your target audience
  3. Identify strengths — what works well and meets the specification
  4. Identify areas for improvement — what could be better and how
  5. Suggest specific improvements — be detailed and actionable, not vague
Critical Rule: Vague evaluation statements like "my product is good" will not earn marks. You must test each specification point specifically, provide evidence of testing, and suggest detailed, actionable improvements.

Practice Questions

Tap each question to reveal the model answer. Try to answer from memory first before checking.

EXPLAINExplain what a loop does in programming and why it is useful.
+
Model Answer
A loop is a programming structure that repeats a block of code a specified number of times (for loop) or until a condition is no longer true (while loop). Loops are useful because they reduce repetition in code — instead of writing the same instruction 100 times, you write it once inside a loop. This makes programs shorter, easier to read, and easier to maintain. For example, for i in range(100): print(i) prints numbers 0–99 in two lines rather than 100 separate print statements.
EXPLAINExplain the difference between a syntax error and a logic error. Give an example of each.
+
Model Answer
A syntax error occurs when you break the rules of the programming language. The program will not run at all. Example: writing if age > 18 without a colon should be if age > 18:.

A logic error occurs when the program runs without crashing but produces the wrong output. The code is valid Python, but the logic is flawed. Example: writing area = length + width instead of area = length * width — the program runs, but the answer is incorrect.

Logic errors are harder to find because there is no error message — you must test your program with known inputs to detect them.
DESCRIBEDescribe the four stages of the MYP Design Cycle and explain what you do at each stage.
+
Model Answer
Stage 1 — Inquire & Analyse (Criterion A): Identify the problem, research the context, analyse existing solutions, and write a design brief that clearly states what you will create and for whom.

Stage 2 — Develop Ideas (Criterion B): Write a detailed specification listing requirements. Generate multiple design ideas, evaluate each against the specification, and justify your chosen solution.

Stage 3 — Create the Solution (Criterion C): Build or code your product following your plan. Document any changes made during creation and justify why they were necessary.

Stage 4 — Evaluate (Criterion D): Test the product against each specification point. Gather user feedback. Identify strengths, weaknesses, and suggest specific improvements.
JUSTIFYA student changes their product's material from plastic to bamboo during manufacturing. Justify why they must document this change.
+
Model Answer
The student must document this change because Criterion C requires recording and justifying all changes to the plan. Changes during creation are expected and acceptable — what matters is the documentation.

They should record: (1) What changed — the material was changed from plastic to bamboo; (2) Why it changed — perhaps bamboo is more sustainable, lighter, or the plastic was unavailable; (3) How it affected the outcome — the product is now more environmentally friendly but may require different joining techniques.

Undocumented changes demonstrate poor process management and result in lost marks, even if the final product is good.
EXPLAINExplain what CAD and CAM are, and how they work together in modern design.
+
Model Answer
CAD (Computer-Aided Design) is software used to create precise 2D and 3D digital models of products. Designers can view, modify, and share designs without physically building prototypes.

CAM (Computer-Aided Manufacturing) uses computers to control manufacturing machines (3D printers, laser cutters, CNC routers) that produce physical products.

They work together: a designer creates a product in CAD, then sends the digital file directly to a CAM machine for manufacturing. This ensures the physical product exactly matches the digital design, reduces human error, enables mass production of identical items, and saves time compared to manual manufacturing.
APPLYWrite pseudocode for a program that asks for a temperature in Celsius and converts it to Fahrenheit. The formula is: F = (C × 9/5) + 32.
+
Model Answer
OUTPUT "Enter temperature in Celsius:"
INPUT celsius
SET fahrenheit = (celsius * 9/5) + 32
OUTPUT celsius + "°C is " + fahrenheit + "°F"
This pseudocode follows the correct structure: take input, process it using the formula, and output the result. In Python, this would be:
celsius = float(input("Enter temperature in Celsius: "))
fahrenheit = (celsius * 9/5) + 32
print(f"{celsius}°C is {fahrenheit}°F")

Flashcard Review

Tap each card to reveal the answer. Try to answer from memory first.

What is an algorithm?
A step-by-step set of instructions to solve a problem. Designed before coding using pseudocode or flowcharts.
Tap to reveal
What are the 4 main Python data types?
String (text), Integer (whole number), Float (decimal number), Boolean (True/False).
Tap to reveal
What is the difference between = and == in Python?
= is assignment (stores a value): x = 5. == is comparison (checks equality): if x == 5. Using the wrong one is a common bug.
Tap to reveal
What is a for loop?
A loop that repeats code a specific number of times. Example: for i in range(5): print(i) prints 0, 1, 2, 3, 4.
Tap to reveal
What is a function in programming?
A reusable block of code that performs a specific task. Defined with def, called by name. Reduces repetition and organises code.
Tap to reveal
Name the 3 types of programming errors.
1. Syntax error (code breaks language rules, won't run). 2. Runtime error (crashes during execution). 3. Logic error (runs but gives wrong output).
Tap to reveal
What is the difference between CAD and CAM?
CAD = designing digitally using software. CAM = using computers to control physical manufacturing machines to cut, shape, or assemble.
Tap to reveal
What are the 4 stages of the MYP Design Cycle?
1. Inquire & Analyse (A), 2. Develop Ideas (B), 3. Create the Solution (C), 4. Evaluate (D). Each maps to an assessment criterion.
Tap to reveal
What must you document when changing your plan during the Create stage?
What changed, why it changed, and how the change affected the outcome (justification for the modification). Undocumented changes lose marks.
Tap to reveal
What is sustainable design?
Designing products that minimise environmental impact — considering materials, energy use, lifespan, recyclability, and social impact throughout the product lifecycle.
Tap to reveal
What is systems thinking?
Understanding how all parts of a system interact and affect each other. Changing one component (e.g., material) affects cost, weight, manufacturing, durability, and environmental impact.
Tap to reveal
What are the 3 stages of Criterion A in Design?
(1) Explain and justify the need/problem, (2) Construct a research plan, (3) Analyse existing products and write a design brief.
Tap to reveal
What is a design brief?
A short, clear statement outlining the problem, target audience, context, constraints, and proposed solution type. It guides the entire design process.
Tap to reveal
What are the 5 flowchart symbols?
Oval (start/end), Rectangle (process), Diamond (decision), Parallelogram (input/output), Arrow (flow direction).
Tap to reveal
What is the difference between a for loop and a while loop?
For loop repeats a set number of times (you know how many). While loop repeats as long as a condition is true (may not know how many times).
Tap to reveal

Practice Test — 20 Questions

0Score / 20
Q 1 / 20
Correct
Wrong
Score