Hacker News new | past | comments | ask | show | jobs | submit login

Here's a random key press loop: function press(key) { var eventObj = document.createEvent("Events"); eventObj.initEvent("keydown", true, true); eventObj.which = key; document.dispatchEvent(eventObj); } for (y=0; y<=1000; y++) { press(Math.floor(Math.random() * 4) + 37); }



Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: