Implemented step5