This repository has been archived by the owner on Nov 17, 2023. It is now read-only.
Loading while scanning #6
-
Any idea how to make a loading screen while the program processes/scans the info from replit? |
Beta Was this translation helpful? Give feedback.
Answered by
darkdarcool
Mar 22, 2021
Replies: 1 comment 9 replies
-
Sure, this is just an idea: import sys
import time
import os
print("pls wait", end ="")
loading = True
loading_speed = 4
loading_string = "." * 6
sun = 0
while loading:
if (sun > 10):
break
os.system("clear")
for index, char in enumerate(loading_string):
sun +=1
if (sun > 10):
break
break
sys.stdout.write(char)
sys.stdout.flush()
time.sleep(1.0 / loading_speed) #
index += 1
sys.stdout.write("\b" * index + " " * index + "\b" * index)
sys.stdout.flush() You can see my repl here: https://replit.com/@darkdarcool/test#main.py |
Beta Was this translation helpful? Give feedback.
9 replies
Answer selected by
kokonut27
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Sure, this is just an idea:
🤔
You can see my repl here: https://replit.com/@darkdarcool/test#main.py