Project 5: Mixing it up

Due: Dec 14th at Midnight


In this project you will use your favorate of the two languages we have looked at this semester to write a program using one of the more recent topics we've covered in class.


Use either python or ruby to do one of the projects below:

  1. Make a simple client-server pair of programs. 
    1. One program, the server, should just listen on a port. (the same port you were supposed to use for your ruby on rails project). When a client connects, the server should accept a text file sent by the client and print that text file to the screen. 
    2. The other program, the client, should initiate a network connection with the server, prompt the user for a text file, open that text file, and then send that text file to the server.
  2. Make a simple multi-threaded program to solve a simple producer consumer problem. 
    1. You need to have a shared data structure
    2. There should be one producer thread. It should add random strings of text (from 4-10 characters long) to the data structure. (add 100 of them)
    3. There should be 2 consumer threads. Each thread should remove a string from the shared data structure, and then print the string along with some identification of the thread which did the consuming.
    4. All three threads should, of course, be running in parallel.
make sure that you make a new folder for this project and do all of your work in that folder.


Be sure to include the usual readme.txt which must include:
Then zip up the whole directory and submit it using the online submission.