UDP client and server with the socket module

In this example, we'll create a synchronous UDP server, which  means each request must wait until the end of the process of the previous request. The bind() method will be used to associate the port with the IP address. For the reception of the message, we use the recvfrom() and sendto() methods for the sending.