title: How can I use Selenium (Python) to do a Google Search and then open the results of the first page in new tabs?
body: <p>As the title said, I'd like to performa a Google Search using Selenium and then open all results of the first page on separate tabs.</p>
  
  <p>Please have a look at the code, I can't get any further (it's just my 3rd day learning Python)</p>
  
  <p>Thank you for your help !!</p>
  
  <h2>Code:</h2>
  
  <pre><code>import time
  from selenium import webdriver
  from selenium.webdriver.common.by import By
  from selenium.webdriver.support.ui import WebDriverWait
  from selenium.webdriver.support import expected_conditions as EC
  from selenium.webdriver.common.keys import Keys
  import pyautogui
  
  query = 'New Search Query'
  
  browser = webdriver.Chrome('/Users/MYUSERNAME/Desktop/Desktop-Files/Chromedriver/chromedriver')
  browser.get('http://www.google.com')
  
  search = browser.find_element_by_name('q')
  search.send_keys(query)
  search.send_keys(Keys.RETURN)
  
  element = browser.find_element_by_class_name('LC20lb')
  
  element.click()
  </code></pre>
  
  <p>The reason why I imported pyautogui is because I tried simulating a right click and then open in new tab for each result but it was a little confusing :)</p>