I am new to python... can anyone help me to use function how to clear python Shell... like using function system("cls") or clrscr()....
| SitePoint Sponsor |
I am new to python... can anyone help me to use function how to clear python Shell... like using function system("cls") or clrscr()....

<?php//Kyle Wolfeecho devBlog("My Dev Notes");
I'm on a GNU/Linux system.
is one way to do it here, but let's face it - that's *way* too much typing just to clear the screen on occasion, so I just press Ctrl+L.Code:import os os.system('clear')
This works fine when running python interactively, using ipython, and in many other applications that can be run from within a *NIX terminal emulator. It probably won't work with IDLE, since that's a Tk app.





Hell I just use it for quickie testing of something, so I ctrl-d and then usually close that terminal window :P

<?php//Kyle Wolfeecho devBlog("My Dev Notes");
Bookmarks