aımnova
DashboardMy LearningCrash CoursesStudy Plan

Aimnova site navigation

Stay in the loop

Get the latest study resources and updates

New features, study tips and exam insights — straight to your inbox.

IB Diploma

  • IB Past Papers
  • IB Study Notes
  • IB Question Bank
  • IB Mock Exams
  • IB Revision

IB Subjects

  • IB Math AA
  • IB Math AI
  • IB Economics
  • IB Business Management
  • IB Physics
  • IB Biology
  • View all IB subjects→

IB Past Papers

  • IB Math AA HL Past Papers
  • IB Math AA SL Past Papers
  • IB Math AI HL Past Papers
  • IB Math AI SL Past Papers
  • IB Economics HL Past Papers
  • IB Economics SL Past Papers
  • IB ESS Past Papers
  • View all past papers→

Study Resources

  • Study Notes
  • Question Bank
  • Mock Exams
  • Crash Courses
  • Flashcards
  • Revision Guide
  • Exam Skills
  • Command Terms
  • Grade Calculator
  • Exam Timetable 2026

Aimnova

  • Features
  • Pricing
  • For Teachers
  • For Schools
  • For Parents
  • About Us
  • Blog
  • Contact
aımnova

IB study, practice and feedback built around the real exam.

TermsPrivacyCookies·© 2026 Aimnova. All rights reserved.c1e448f

Aimnova is not affiliated with or endorsed by the International Baccalaureate Organization (IB).

NotesComputer Science HLTopic 5.1Tracing flowcharts
Back to Computer Science HL Topics
5.1.44 min read

Tracing flowcharts (Computer Science HL)

IB Computer Science · Unit 5

Your first topic is free to keep

Know exactly what to write for full marks

Practice with exam questions and get AI feedback that shows you the perfect answer — what examiners want to see.

Start Free

Contents

  1. 1Following an algorithm one step at a time
  2. 2The symbols
  3. 3How to trace without mistakes
  4. 4Exam-style question
The big idea: Tracing means working through an algorithm by hand, writing down every variable after every step.

It is slow and mechanical on purpose — the whole value is that you never guess what happens next.

A flowchart adding 1 to N, traced step by step. Use Next step to go at your own pace.

Interactive diagram

Explore the labelled diagram, charts and maps for this topic in full study mode.

Claim your free topic

Free preview

This is the free notes preview

You're reading the free notes. Aimnova Pro unlocks the full study experience — and you can try it with your first topic free to keep:

  • FlashcardsLock in vocabulary and key terms with spaced repetition.
  • Practice questionsAnswer exam-style questions and get instant AI marking.
  • Mock exams & past-paper vaultSit full mocks and see exactly how examiners award marks.
  • Personalised study planA daily plan built around your exam date and weak areas.
Start Studying Free Full access to Aimnova Pro · cancel anytime

Where it starts and stops

  • Start / End — a rounded box, one at each end
  • Exactly one Start; there may be more than one End
  • Flowline — an arrow showing which way control goes

Doing things

  • Input / Output — a slanted box: reading a value or showing one
  • Process — a plain rectangle: a calculation or an assignment
  • One action per box, so the trace has one row per box

Choosing and joining

  • Decision — a diamond, with a question inside it
  • Exactly two flowlines out, labelled Yes and No
  • Connector — a small circle joining parts of a large chart, or a page to the next
The diamond is where loops live: A flowchart has no separate loop symbol.

A loop is a decision whose No branch carries on and whose Yes branch leads back up — or the reverse. Follow the arrows and the loop is obvious.

Stop wasting time on topics you know

Our AI identifies your weak areas and focuses your study time where it matters. No more overstudying easy topics.

Try Smart Study FreeYour first topic is free to keep • No credit card required
1

1 — Draw the table first

One column per variable, plus one for output.

Doing this before you start is what stops you losing track halfway through a loop.

2

2 — One row per step, always

Write a new row every time any value changes, even when the change looks trivial.

Skipping rows to save time is the single most common cause of a wrong trace.

3

3 — At a diamond, write the test out

Do not decide the branch in your head. Write "is 4 at most 3? No" and then follow that arrow.

The boundary cases — where the values are equal — are where most errors happen.

4

4 — Output is a column too

Give output its own column and add to it only when an output box is reached.

Many questions ask only "what is printed", and the trace table is where that answer already is.

Watch the order inside a loop: Whether the counter increases before or after the calculation changes the answer.

Trace what the chart actually shows, in the order the arrows go — not what you assume it meant.

How this is tested — you must produce a complete trace table and read the output from it. It comes up two ways:

Paper 2 — working with code

  • Trace a flowchart and state the output, 4-6 marks
  • Complete a partly-filled trace table
  • Say what the algorithm does in general

Paper 2 — the algorithmic-thinking question

  • Often the no-code question: a flowchart, a trace table and an output
  • Sometimes: find the error a trace reveals
The classic trap: Getting the boundary wrong. When the test is "count at most N", the loop runs when they are equal — one extra time round. Write the comparison out at every diamond and you cannot slip.
IB-style questionTrace[5 marks]

A flowchart reads N, sets total to 0 and count to 1, then while count is at most N adds count to total and increases count by 1, finally printing total. Trace it for N = 4.

Model answer plan

See the answer broken into clear points, with guidance on how each point earns marks.

Claim your free topic

Try an IB Exam Question — Free AI Feedback

Test yourself on Tracing flowcharts. Write your answer and get instant AI feedback — just like a real IB examiner.

the output of this Java code.

int a = 3;
int b = 7;
if (a > b) {
System.out.println(a);
} else {
System.out.println(b);
}
[1 mark]

Related Computer Science HL Topics

Continue learning with these related topics from the same unit:

5.1.1Problem specification5.1.2Computational thinking5.1.3Applying the concepts
View all Computer Science HL topics
Improve your exam techniqueCommand terms, paper structure, and mark-scheme tips for Computer Science HL
Previous5.1.3Applying the conceptsNextVariables and data types6.1.1

40 exam-style questions ready for you

Students who practice on Aimnova improve their scores by 15% on average. Get instant feedback that shows exactly how to improve your answers.

Practice Now — FreeView All Computer Science HL Topics