Git and GitHub exercises with solutions
45 practice problems from the 15 lessons of the Git & GitHub course, in lesson order and from easy to hard inside each lesson. Open a problem, write your code and press Submit: the tests run in your browser and nothing is sent to a server.
15 easy problems 15 medium problems 15 hard problems
Version control and your first repository
3 problems · Read the lesson
Staging and committing
3 problems · Read the lesson
Viewing changes: diff, log and blame
3 problems · Read the lesson
Inside Git: objects and hashes
3 problems · Read the lesson
Inside Git: trees and commits
3 problems · Read the lesson
Branches, HEAD and revision names
3 problems · Read the lesson
Working with branches
3 problems · Read the lesson
Merging
3 problems · Read the lesson
Resolving merge conflicts
3 problems · Read the lesson
Undoing changes: restore, reset, revert and the reflog
3 problems · Read the lesson
Rebasing
3 problems · Read the lesson
Stashing work and tagging releases
3 problems · Read the lesson
Remotes: clone, fetch, pull and push
3 problems · Read the lesson
Pull requests and conventional commits
3 problems · Read the lesson
.gitignore and GitHub Actions
3 problems · Read the lesson