I have a guess of what you're going for, but I think it would be better if you asked a more specific question. A while loop has two parts: The logic inside of the loop, and the condition (a boolean expression) that the loop loops on.
Start with this: What do you want the while loop to do?