Update node13.sc

If success, should stop while loop, i + 1 if encounter a failure.