Task 4 with semaphores uploaded

I added most of my code right underneath the global variable
declarations. I tried to put the functions with the rest of the other
functions but my compiler didn't like my task 4 being listed after the
Threadtest function. I'm using Centos 6.0 so maybye that is why.

Anyway Project 4 is complete