Introduction
Merge conflicts happen when two people change the same part of a file in different ways. Git cannot decide which change to keep automatically, so it asks you to fix it.
When two developers edit the same line in a file and try to merge their changes.
When you update your branch but someone else changed the same code in the main branch.
When you rebase your work on top of new commits that touch the same files.
When merging feature branches that have overlapping changes.
When pulling changes from a remote repository that conflict with your local edits.