TCP was designed by the Defense Advanced Research Projects Agency (DARPA) in the 1970s for use in the Advanced Research Projects Agency Network (ARPANET). It complements IP and, thus, is also referred to as TCP/IP. The TCP protocol, even by its name, indicates that it provides reliable (that is, error-checked or controlled) data transmission. It allows the ordered delivery of bytes in an IP network and is widely used by the web, email, secure shell, and file transfer.
An application that uses TCP/IP is not even aware of all the handshaking that takes place between the socket and the transmission details – such as network congestion, traffic load balancing, duplication, and even loss of some IP packets. The underlying protocol implementation of the transport layer detects these problems, resends the data, reconstructs the order of the sent packets...