A simple and cross-platform solution would be to use either the cls
command on Windows, or clear
on Unix systems. Used with os.system
, this makes a nice one-liner:
import os
os.system('cls' if os.name == 'nt' else 'clear')
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…