LESSON 03 / 3·2 min readFoundation

How do I resolve a merge conflict or find a bad commit?

01 Understand02 Recall03 Prepare

Understand the concept

A merge conflict means Git cannot automatically decide how competing changes should combine. Resolving it requires understanding the intended behavior, not just removing conflict markers. Bisect solves a different problem: it narrows the commit range that introduced a reproducible regression through repeated good/bad checks.

Important ideas

  • Read both changes and preserve the intended combined behavior.

  • Run relevant checks after resolving conflicts; do not choose a side blindly.

  • Use git bisect with known good and bad commits to narrow down a regression.

  • A useful bisect check must be repeatable; flaky tests can identify the wrong commit.

PAUSE & RECALL

Can you explain it without the notes?

How do I resolve a merge conflict or find a bad commit?

Use your own words. Explain an example and one limitation before checking the explanation.

Check your explanation

A merge conflict means Git cannot automatically decide how competing changes should combine. Resolving it requires understanding the intended behavior, not just removing conflict markers. Bisect solves a different problem: it narrows the commit range that introduced a reproducible regression through repeated good/bad checks.

CONNECT IT TO YOUR INTERVIEW

Turn this concept into a clear answer.

  • Re-run the affected behavior after conflict resolution because syntactically valid combined code can still be logically wrong.
Practice this concept
YOUR NEXT STEP

You’ve reached the end of this guide.

Prepare for Git interviews

Adapted from 09_TESTING_GIT_DOCKER_CLOUD.md · “How do I resolve a merge conflict or find a bad commit?”. Examples are study fragments; framework behavior can depend on your version.