How do I make my text in Python disappear when the user presses a key?
How do I make my text in Python disappear when the user presses a key?
Voters
Bookie0
i think you can also use this:
print('\033c')
or this:
print('\x1bc')
hope this helps as well! =)
CoolJames1610
reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee @Bookie0
CoolJames1610
from os import system def clear(): system("clear") clear()
OR
import os os.system("clear") # whenever you want to clear the screen
Hope this helped :)
Please mark this answer if it helped
you can do this:
you can also make
os.system('clear')
into a function for easier coding:hope this helps! =)
UH COPYCAT xD @Bookie0
how? theres only that i think, and I always put it into a function so that its easier. Plus, i added comments XD @CoolJames1610
smh xD copycat :P @Bookie0
i also put it in a function @Bookie0
smh
uneccessary pinging@CoolJames1610smh
smh@Bookie0btw pls check my new project
you dont have to@Bookie0which one (also you should stop pinging, especially for the person who posted this ask)
@CoolJames1610
oh wow. @Bookie0
? @CoolJames1610