this is the code, and when i start it, its really fast, is there any way to make the loop a little slower? first it didnt show the counting, but then i fixed it by adding the count function. first it wasnt counting down, but i fixed that by adding the count function.
JavaScript
x
18
18
1
import pyautogui
2
import time
3
4
msg = input("Enter the message: ")
5
n = input("How many times ?: ")
6
7
print("spamming in")
8
9
count = 5
10
while(count != 0):
11
print(count)
12
time.sleep(1)
13
count -= 1
14
15
16
for i in range(0,int(n)):
17
pyautogui.typewrite(msg + 'n')
18
Advertisement
Answer
You can make it slower the same way you made the while loop slower, add a time.sleep
call:
JavaScript
1
4
1
for i in range(0,int(n)):
2
pyautogui.typewrite(msg + 'n')
3
time.sleep(0.1) # the greater the number is, the more delay.
4