Having setup the server, we now need to tell Python what to do when a request is made on the given port. For this we reference the request by its value and use it as the argument of a persistent while loop.
When a request is made, the server should accept the request and create a file object to interact with it.
while 1:
csock, caddr = c.accept()
cfile = csock.makefile('rw', 0)
In this case, the server uses the same port for reading and writing. Therefore, the makefile method is given an argument 'rw'. The null length of the buffer size simply leaves that part of the file to be determined dynamically.

