Update car.c

Implement locking using reader writer semaphore
Merge pull request #2 from kgcorner/rwsemaphore

Update car.c