Middle
What is the difference between TCP and UDP?
sobes.tech AI
Answer from AI
TCP and UDP are two transport layer protocols with different characteristics.
-
TCP (Transmission Control Protocol) is connection-oriented, providing reliable, ordered delivery of data. It uses acknowledgments, retransmissions, and flow control.
-
UDP (User Datagram Protocol) is connectionless, does not guarantee delivery or order of packets, but operates faster and with lower overhead.
Example: when loading a web page, TCP is used, while for real-time voice transmission, UDP is preferred due to minimal latency and tolerance for some packet loss.