Thanks Geoff. I was actually planning to use a general loop for calculation of digital root. I got intrigued by one of the entries in Buttonshy's latest 18-card game submission contest.
do {X = INT(A/10) + A%10} while X > 9
Well... It would take the integer and the condition and would somehow have to link to the operations that get repeated.
And do...while is different to while...do, you might want to implement both.
Apologies for coming at this as a programmer used to working with single values - I think the tools is meant more as mathematical operations on sets. I have never really learned that.