Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialayub ali
Courses Plus Student 723 Pointsshow me how to delete the input of the console
when i am creating a code inside the code i can't delet the program output
Chris Freeman
Treehouse Moderator 68,457 Points- If you need to exit the Python interactive REPL, use
exit()
orquit()
$ python
Python 3.5.0 (default, Nov 28 2017, 19:33:11)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-16)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()
- If you need to clear the contents of the console use
clear
treehouse:~/workspace$ clear
1 Answer
Krishna Pratap Chouhan
15,203 PointsAhh so you meant something like this...
import sys
def fun():
sys.stdout.write("Hello World!")
sys.stdout.flush()
sys.stdout.write("\b"*6)
sys.stdout.write("Earth!!!")
fun()
Or maybe not.
charlesmonaghan
742 Pointscharlesmonaghan
742 PointsWhat do you mean? Could you please post a screenshot. :)