Implemented LoopADT correctly and fixed appropiate places