git checkout
git checkout <commit>
Risk: Careful
What it does
The older way to switch branches or visit commits.
When to use it
You will see it in old guides. Prefer switch and restore.
Example
$ git checkout a1b2c3dVisit commit a1b2c3d (detached HEAD).
Learn it in: Detached HEAD · Official docs