Page 1 of 1

Using the programming language of your choice, write two sets of client-server programs. In one set, the client and the

Posted: Fri Jul 08, 2022 6:35 am
by answerhappygod
Using the programming language of your choice, write two sets ofclient-server programs. In one set, the client and the servercommunicate over TCP, while in the other they communicate over UDP.In both sets, the client sends a “hello” message to the server, andthe server replies with “back at you”. The client then computes andprints the RTT. You must use sockets directly; you cannot use anyhigher-level frameworks.
a) Attach the source code of your programs and the resultingscreenshots for each set.
b) How do the RTTs of UDP and TCP compare? Explain why it’sso.
c) If both servers run simultaneously and use the same portnumber, won’t the clients be mixed up when they contact theircorresponding server on that port number? Why?