Juniper Networks interview question

Implement semaphore and mutex locks