First install pyautogui using pip
> pip install pyautogui
Code:-
import pyautogui, time
time.sleep(2)
x = 0
times = 20 # Change this to the number of times you want it to click
while True:
if x == times:
print("Stopped Clicking")
break
else:
pyautogui.leftClick()
x += 1
This code left clicks the number of times set in the variable times (Here, it is 20 times)
First install pyautogui using pip
`pip install pyautogui`
Code:-
```
import pyautogui, time
time.sleep(2)
x = 0
times = 20 # Change this to the number of times you want it to click
while True:
if x == times:
print("Stopped Clicking")
break
else:
pyautogui.leftClick()
x += 1
```
This code left clicks the number of times set in the variable `times` (Here, it is 20 times)