← Back

Git Bisect

Debug the Bug with Binary Search

What is Git Bisect?

Git bisect is a powerful debugging tool that uses binary search to find which commit introduced a bug. Instead of checking every commit linearly, you divide the history in half repeatedly, dramatically reducing the number of commits you need to inspect.

How it works:

  • Start with a range of commits: one "good" (before the bug) and one "bad" (has the bug)
  • Git checks out the middle commit
  • You test and mark it as "good" or "bad"
  • Git eliminates half the remaining commits
  • Repeat until you find the exact breaking commit

For 16 commits, linear search takes up to 16 checks. Binary search? Just 4! That's the power of O(log n).

Your Mission

Complete 8 debugging rounds. Each round presents a git history with one breaking commit. Git checks out the midpoint commit for you — test it, mark it good or bad, and watch the candidate range collapse until only the breaking commit remains.

Scoring: You start with 200 points per round. Each inspection beyond the optimal number costs you 30 points. Find bugs efficiently to maximize your score!

Git Bisect

Round 1 / 8
Score: 0

Bug Report

Bisect Status

Commits Remaining: 16
Checked Out: --
Inspections: 0
Optimal: 4

Only the checked-out commit (highlighted below) can be tested and marked. Mark Good if the bug is absent — the first bad commit is newer. Mark Bad if the bug is present — this commit or an older one introduced it.

Game Complete!

Debugging Master Achievement Unlocked

0
0
Rounds Completed
0
Total Inspections
0%
Avg Efficiency