Add while loop