fix issue with SimpleSemaphone and week 4 assignment
final SimpleSemaphone improvement