Book a free demo

๐Ÿ’ป Coding games ยท free, no sign-up

Bug hunter: find the line that is wrong.

Play Bug Hunter

Loading Bug Hunterโ€ฆ

Real programmers spend more time fixing code than writing it. Each round shows a short Python program that prints the wrong thing. Tap the buggy line and see why.

ShareWhatsApp

How to play Bug Hunter

  1. Choose a level: Beginner, Loops and functions, or Trickier programs.
  2. Read what the program should print and what it actually prints.
  3. Tap the line you think has the bug. A first-time find scores 20 points.
  4. Read the fix and the reason, then move to the next bug.

Tips and strategy

  • Run the program in your head, line by line, and write down what each variable holds.
  • Find the first line where the value stops matching what you expect.
  • Check the usual suspects: the wrong operator (+ instead of ร—), a loop that stops one too early, a counter that starts at the wrong number.
  • Read the goal carefully: sometimes the bug is that a line does a different job from the one asked.

Keep playing

More games you might like

All 116 games โ†’

FAQ

Bug Hunter: questions

What is a bug in coding?

A bug is a mistake in a program that makes it behave in a way you did not plan, such as printing the wrong number or stopping with an error.

How do I find a bug in my Python code?

Trace the code line by line, writing down what each variable holds, or add print() lines to show values. The bug is at the first place where a value is not what you expected.

What is an off-by-one error?

A loop or index that is one too few or one too many, such as range(1, 5) when you wanted 1 to 5. It is the most common beginner bug.

Is this game for beginners?

Yes. Level 1 uses only variables, print and simple loops. You do not need to write any code, only read it.

Start a conversation

Questions about classes?

A parent or guardian can share the learner's age, level and goals, and we'll suggest a starting point and confirm the format before anything is booked.

  • Tell us the learnerโ€™s age or grade and goals
  • Weโ€™ll suggest a suitable class or learning path
  • Weโ€™ll confirm format, timing and fees with a parent or guardian

For a childโ€™s class, please have a parent or guardian send the enquiry. Avoid sharing passwords or sensitive personal details.

Weโ€™ll use your details only to respond to this request.

Chat on WhatsApp
Esc

Try