Create threadserver.c

This file is to be run on the server. This is a server part of the project.