In order to explain Git, we have to first explain various aspects of Version Control.
Version Control Version Control is a system that allows you to revisit various versions of a file or set of files by recording changes. Through version control, one can
By utilizing a Version Control System (VCS), mistakes with files can easily be rectified.


is a DVCS that stores data in a file system made up of snapshots. Each time you save a changed version of your project — called commit — Git creates a snapshot of the file and stores a reference to it. If the file has not changed, Git only stores a reference to the already-stored identical version of it.
Relies on local operations because most necessary information can be found in local resources.
Detect file corruption or loss of information in transit.
Minimize the possibility of irreversible damage to files.
States

#### The local Git repository has three components:

All files in a checked out (or working) copy of a project file are either :
| Tracked | Tracked files can be modified, unmodified, or staged; they were part of the most recent file snapshot |
|---|---|
| Untracked | Untracked files were not in the last snapshot and do not currently reside in the staging area. |
After cloning a repository, files have tracked status and are unmodified because they have been checked out but not edited.
