What is the difference between TCP and UDP? (And what do they stand for?)
Sigiloso
I said that TCP is reliable and stateful, while UDP is stateless. TCP guarantees reliable communication through the 3-way handshake (SYN, SYN/ACK, ACK), which allows both sides to synchronize sequence numbers and ack numbers. UDP is just a firehose of data, with no built-in mechanism to ensure correct, complete data transfer. TCP would be used for something like loading a webpage, where you want it to be loaded fully, in the correct order, and correctly. UDP would be used for realtime communication, like a video call, where it's ok if some of the bits are slightly incorrect, and latency is far more important.