Methods
Creates and runs a thread
Sleeps for a given number of milliseconds
Waits for a thread to end
Create and initialize a semaphore, with an empty wait queue, and couter=' val'
'P' Operation on the 'sem' semaphore';
its counter is decremented;
if counter < 0, then the calling task is moved to the wait queue
'V' Operation on the 'sem' semaphore';
its counter is incremented;
if counter >= 0 and the wait queue is not empty,
then one of the waiting tasks is extracted to continue running