DevOps & Cloud 路 Intern to senior

Git Interview Questions and Answers

Every engineering role uses Git, so almost every interview loop includes a few questions about it. Interviewers want to know you can work on a shared branch without losing work, explain what a command does to history, and recover when something goes wrong.

Download Git PDF5 questions

4 of 5 questions match

Clear filters
  • GitEasy

    What is Git and how is it different from GitHub?

    Git is a distributed version control system that tracks changes to files on your machine; GitHub is a hosting service for Git repositories that adds collaboration features such as pull requests, code review and CI.

    Intern 路 Junior 路 Git
  • GitEasy

    What is the difference between git fetch and git pull?

    git fetch downloads new commits from the remote without changing your working branch; git pull runs a fetch and then merges (or rebases) those commits into your current branch.

    Intern 路 Junior 路 Git
  • GitMedium

    What is the difference between git merge and git rebase?

    Both integrate changes from one branch into another: merge keeps both histories and joins them with a merge commit, while rebase rewrites your commits so they appear on top of the target branch, giving a linear history.

    Junior 路 Mid-level 路 Git
  • GitMedium

    How do you resolve a merge conflict in Git?

    Open the conflicted files, decide what the final code should be between the conflict markers, remove the markers, run the tests, then stage the files and continue the merge or rebase.

    Junior 路 Mid-level 路 Git