Intermediate Git & Version Control
Q61 / 100

What is the difference between "origin/main" and "main" as seen in "git branch -a" output?

Correct! Well done.

Incorrect.

The correct answer is A) "main" refers to the local branch, while "origin/main" is a local reference (remote-tracking branch) representing the state of the "main" branch on the "origin" remote as of the last fetch — they can diverge if either side gets new commits

A

Correct Answer

"main" refers to the local branch, while "origin/main" is a local reference (remote-tracking branch) representing the state of the "main" branch on the "origin" remote as of the last fetch — they can diverge if either side gets new commits

Explanation

Remote-tracking branches (like "origin/main") are read-only local bookmarks updated by "git fetch"/"git pull" — they reflect the remote's state at the time of the last fetch, not necessarily its current state.

Progress
61/100