Apple interview question

Difference between semaphor, lock, and control variables.