#include <cstdio>
#include <cmath>
#include <ctime>
#include <cstdlib>
#include <conio.h>
#include <windows.h>
using namespace std;
int main () {
srand (time (0));
while (1) {
if (GetAsyncKeyState ('Q')) {
while (1) {
int x = rand () % 1600;
int y = rand () % 900;
POINT p;
GetCursorPos (&p);
SetCursorPos (p.x = x, p.y = y);
mouse_event (MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
Sleep (1);
mouse_event (MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
if (GetAsyncKeyState (VK_SPACE)) break;
}
}
}
return 0;
}