What is peer-to-peer?
To understand what peer-to-peer is, we first need to understand what a server and a client relation is.
A server is a computer running all the time, waiting for a client to request data. As an example, a user browsing through his web is communicating with many different servers. One server is sending the webpage, another to download all the images. The server has complete control over all the data.
In a peer-to-peer network, every computer is a client and a server. Every computer can receive and send data to another one. A basic example is a peer-to-peer network, where one computer has access to the internet, and another one has access to a printer. The computer with access to the internet can send a file to print to the computer connected with the printer. So the computer can print something without being connected to the printer at all. Vise versa, the computer connected to the printer can request data from the internet.
Other examples of use
Messaging
Imagine having a messenger app in a typically client-server relation. One client sends a message, and then the server receives this message. After processing the message, it sends out a push-up notification to the receiver of the message.
In a peer-to-peer network, the message's sender could have directly sent the message to the receiver. The receiver can then directly send a message back without having a server in the middle of those two clients.
Sharing files
Imagine computer A in a peer-to-peer network of computers wants to access a file called “image.png”. The file image.png is not stored on the hard drive, so computer A sends a broadcast to all other computers, asking if they have a file called “image.png”. If one has so, then computer A can download it from the other computer.
Conclusion
A peer-to-peer is a network of computers that are all directly connected.