On 05/06/2024 04:09, Cameron Simpson wrote:
On 04Jun2024 22:43, Rob Cliffe wrote:
import os
def cls(): x=os.system("cls")
Now whenever you type
cls()
it will clear the screen and show the prompt at the top of the screen.
(The reason for the "x=" is: os.system returns a result, in this case
On 04Jun2024 22:43, Rob Cliffe wrote:
import os
def cls(): x=os.system("cls")
Now whenever you type
cls()
it will clear the screen and show the prompt at the top of the screen.
(The reason for the "x=" is: os.system returns a result, in this case
0. When you evaluate an expression in the IDE
Welcome to Python! A great language for program development.
Answers might be platform-dependent (are you using WIndows, Linux, etc.).
However, the following works for me on WIndows. You can put it in the
startup.py file so you don't have to type it every time you start up the
IDLE.
import