# Git Assignment ## 1. What is Git and Version Control What problem does Git solve? Git solves the problem of tracking changes in code and coordinating work across multiple developers. Real-life example where multiple people edit the same file: Real-life example: Several people editing a shared report in Word at the same time leads to conflicts and lost edits. Why is version control better than emailing files back and forth? Version control is better than emailing files because it keeps a single source of truth with automatic history and collaboration tools. ## Git Version Check ![Git version check](git.version.png) --- ## 2. Installing Git & Configuring User Info ![Git status](Config.png) --- ## Git List ![Git status](git.list.png) --- ## 3. Initializing a Repository ## Git Init ![Git add](git_int.png) --- ## 4. Working Directory, Staging, and Commits ## Git Add ![Git add](add_commit.png) --- ## 5. Adding & Committing Files ## Git Log ![Git log](git_log.png) --- ## 6. Viewing Commit Logs & Diffs ## Git Log (graph) ![Git log graph](git log_oneline.png) --- ## Git Diff ![Git diff](git_diff.png) --- ## Git Diff (commit1 vs commit2) ![Git diff between two commits](git_diff_between_commits.png) ---