update while loop with until