Well... that is the most elegant way of getting out of the loop but...

Unfortunately does not meet the customer's requirement to save the current count.

So with (or without) your permission, will modify:

$current = $X
$X = 13
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.