Interview Q&A / Git & GitHub

BeginnerQuick answer1 min readUpdated 3 Oct 2026

What do the <<<<<<<, ======= and >>>>>>> markers in a file mean?

SHORT ANSWER

They are Git's conflict markers. The part between <<<<<<< and ======= is your current branch's version, and the part between ======= and >>>>>>> is the incoming version. You edit the file to the final text and delete all three marker lines.

Explain it simply

When two people rewrite the same line of a shared notice, Git cannot choose. It prints both versions in the file, separated by markers, and waits for you.

The top half, after <<<<<<< HEAD, is what your branch has. The bottom half, ending at >>>>>>> feature, is what came in. Decide what the final text should be: one side, the other, or a blend. Delete the marker lines, save, git add the file and commit. If a marker line is left behind, the code will not compile.

Example

text
<<<<<<< HEAD
const fee = 49;
=======
const fee = 59;
>>>>>>> feature/pricing

# resolved:
const fee = 59;

What to say in the interview

"The markers show both competing versions: above ======= is my current branch, below is the incoming one. I edit to the intended final code, remove all marker lines, stage the file and commit. I always search for leftover markers before committing."

Common mistakes

  • Committing with the marker lines still inside the file.

#git#conflicts#merge

Related questions

Practise more Git & GitHub questions

Test your recall with short answers, then return to the detailed explanations when you need context.

Open Git & GitHub quick answers →

Get new questions like this by email

One short email when something new and useful lands. No spam, unsubscribe in one tap.

By subscribing you agree to the Privacy Policy.