Implemented the Loop code.