Final answer:
In a peer-to-peer network, a computer can assume the roles of a client and server or sender and receiver when sharing a file.
Step-by-step explanation:
In a peer-to-peer network where a file is being shared between two computers, the two roles that a computer can assume are 1) Client and Server, and 2) Sender and Receiver.
- Client and Server: In this role, one computer acts as a server that hosts the file and responds to requests from the other computer, which acts as a client.
- Sender and Receiver: In this role, one computer sends the file to the other computer, which receives the file.
Both these roles require the computers to establish a direct connection with each other in order to share the file.