forgot to end the while function