# Why Version Control Exists: The Pendrive Problem

The **"Pendrive Problem"** is a classic analogy used in software development to describe the risky, and inefficient way developers used to collaborate before **Version Control Systems** (**VCS**) like Git existed.

## The Core Issues of the Pendrive

If two developers, developer1 and developer2, both need to fix a bug in the same file (`login.js`), they can't work at the same time. If developer1 finishes work, saves it to the pen-drive, and then developer2 finishes work and saves *his* version to the same pen-drive, developer1 changes are gone**.** developer2’s version simply overwrote because the pen-drive has no memory of what was there before.

### Without a system to track versions, developers resorted to manual folder naming. Project directory would eventually look like this:

* project\_v1
    
* project\_final
    
* project\_final\_v2
    
* project\_final\_REAL\_FINAL\_v3
    
* project\_DONT\_DELETE\_THIS\_ONE
    

### When the code suddenly breaks, there is no way to know:

* **Who** changed the line that broke it?
    
* **When** was the change made?
    

### Fix The Missing Bug

Imagine a team of three building an project.

* *De****veloper1*** adds a "Dark Mode" feature and passes the pendrive to *Developer2*.
    
* *Developer2* fixes a bug in the payment gateway and passes it to *Developer3*.
    
* *Developer3* accidentally deletes a folder while cleaning up and gives the pendrive back to the team.
    
* *Result:* The "Dark Mode" is there, but the **bug fix is gone**, and half the site is broken because of the deleted folder. Because they used a pendrive, they can't "undo" Developer 3's mistake.
    

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1768581707334/addc37bc-e0c7-4148-b560-fed56d86df52.png align="center")

# Why Version Control is the Solution

Version control systems were created to turn "The Pendrive Problem" into a structured workflow. Instead of passing a physical stick, developers **Commit** their changes to a timeline. If something goes wrong, you don't look for a folder named `final_v2`; you simply **Rollback** the timeline to a point when the code was working.

Using This Version control systems :-

* Everyone works simultaneously.
    
* Git flags "Merge" to be resolved.
    
* Every single change is recorded.
    
* Every developer has a full backup (clone).
    

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1768582380723/afa1b1cd-f4b5-40ad-9139-4c1c7c9d41af.png align="center")
