Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from time import sleep
- print_count = 0
- def myprint(stuff, erase=0):
- global print_count
- print(stuff)
- print_count += 1
- if erase == 1:
- for i in range(0,print_count):
- print("\033[F", end="")
- print("\033[K", end="")
- myprint("Some stuff printed bla bla bla")
- myprint("Some other stuff printed")
- myprint("now we're gonna delete these 3 lines")
- sleep(1)
- myprint("", 1)
- myprint("Ok so now we're printing some stuff and you input something below:")
- yours = input()
- myprint("Ah, yes... " + yours + " indded.")
- myprint("Now time to erase all this...")
- sleep(1)
- myprint("", 1)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement