
"""simple docstring"""

import webbrowser
from sys import argv
from urllib.parse import parse_qs, quote

import requests
from bsa import BeautifulSoup
from fake_useragent import UserAgent

if __name__ == "__main__":
					_A						=			'%20'.join(argv[1:]) if len(argv) > 1 else quote(str(input('Search: ')))

					print('Googling.....')

					_A						=			F"""https://www.google.com/search?q={query}&num=100"""

					_A						=			requests.get(
					    url,
					    headers={'User-Agent': str(UserAgent().random)},
					)

					try:
										_A						=			(
										    BeautifulSoup(res.text, 'html.parser')
										    .find('div', attrs={'class': 'yuRUbf'})
										    .find('a')
										    .get('href')
										)

					except AttributeError:
										_A						=			parse_qs(
										    BeautifulSoup(res.text, 'html.parser')
										    .find('div', attrs={'class': 'kCrYT'})
										    .find('a')
										    .get('href')
										)['url'][0]

					webbrowser.open(link)








"""simple docstring"""

def 		UpperCAmelCase (		a_,						a_      ):





		'''simple docstring'''


		while b:
				lowerCamelCase     ,   lowerCamelCase					:      Tuple          =   b, a % b
		return a
def 		UpperCAmelCase (		a_,						a_      ):





		'''simple docstring'''


		return a if b == 0 else euclidean_gcd_recursive(a_,						a % b      )
def 		UpperCAmelCase (		):





		'''simple docstring'''


		print(F"""euclidean_gcd(3, 5) = {euclidean_gcd(3,						5      )}"""      )
		print(F"""euclidean_gcd(5, 3) = {euclidean_gcd(5,						3      )}"""      )
		print(F"""euclidean_gcd(1, 3) = {euclidean_gcd(1,						3      )}"""      )
		print(F"""euclidean_gcd(3, 6) = {euclidean_gcd(3,						6      )}"""      )
		print(F"""euclidean_gcd(6, 3) = {euclidean_gcd(6,						3      )}"""      )

		print(F"""euclidean_gcd_recursive(3, 5) = {euclidean_gcd_recursive(3,						5      )}"""      )
		print(F"""euclidean_gcd_recursive(5, 3) = {euclidean_gcd_recursive(5,						3      )}"""      )
		print(F"""euclidean_gcd_recursive(1, 3) = {euclidean_gcd_recursive(1,						3      )}"""      )
		print(F"""euclidean_gcd_recursive(3, 6) = {euclidean_gcd_recursive(3,						6      )}"""      )
		print(F"""euclidean_gcd_recursive(6, 3) = {euclidean_gcd_recursive(6,						3      )}"""      )


if __name__ == "__main__":
					main()






