Here is the function causing the trouble - I am trying to clean it up and make it more efficient/easier to read. When I make a change in the conditional statement it zeros the global variable .
by global - I mean it is declared by the statement outside of any function, then set inside another function by the statement
Any suggestions much appreciated.
display(); // prints out mins, secs and cent - it does not change them.
if(timeToRun>100) // go round the function again - this causes the trouble
else // leave the loop - countdown completed - this works all the time
// alternative comparison that is less efficient but works! (cent>10 || secs!=0 || mins!=0)
Still thinking and still very puzzled, but putting this together has helped a little.