Created
October 27, 2023 10:53
-
-
Save Pixailz/d179ee721ce8493c87adde43acf72d7a to your computer and use it in GitHub Desktop.
testing of clearing a screen with ANSI Esc Seq
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import time | |
[ print(f"{i + 1} test") for i in range (0, 100) ] | |
def clear_screen(): | |
print("\x1b[2J\x1b[H", end="") | |
print("should clear the screen in 3sec") | |
time.sleep(3) | |
clear_screen() | |
print("^^^NOTHING ABOVE^^^") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment