import time import sys for i in range(100): time.sleep(1) sys.stdout.write(" %d%%" % i) sys.stdout.flush()