added comments to code, fixed bug with lower priority missed deadline