Python provides a module called "google" with which you can access google. You can use something like this:
from googlesearch import search
print("No module named 'google' found")
# to search
query = "Edureka"
for j in search(query, tld=".com", num=5, stop=1, pause=2.0):