import ansi_escape, sys, time print("Hello World!!", end='') time.sleep(1) a = 0 while a < 5: a += 1 sys.stdout.write(ansi_escape.backspace)