SHARE
TWEET

win at google.

TankorSmash Aug 7th, 2012 1,486 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from selenium import webdriver
  2. from selenium.webdriver.common.keys import Keys as k
  3. br = webdriver.Chrome()
  4.  
  5. br.get(r'http://google.com')
  6.  
  7. elem = br.find_element_by_id('hplogo')
  8.  
  9. def mashButton(loops):
  10.   for i in xrange(loops):
  11.      elem.send_keys(k.LEFT)
  12.      elem.send_keys(k.RIGHT)
  13.  
  14. mashButton(200)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top