Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # python3 GoogleSearch.py
- # Using Firfox or its default browser
- from googlesearch import *
- import webbrowser
- #to search, will ask search query at the time of execution
- query = input("Input your query:")
- chrome_path = r'/usr/bin/chromium-browser'
- for url in search(query, tld="com", num=1, stop = 1, pause = 2):
- webbrowser.open("https://google.com/search?q=%s" % query)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement