





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__":
       _SCREAMING_SNAKE_CASE  :						List[str]         =    '''%20'''.join(argv[1:]) if len(argv) > 1 else quote(str(input('''Search: ''')))

       print('''Googling.....''')

       _SCREAMING_SNAKE_CASE  :						List[Any]         =    F"https://www.google.com/search?q={query}&num=100"

       _SCREAMING_SNAKE_CASE  :						Optional[int]         =    requests.get(
           url,
           headers={'''User-Agent''': str(UserAgent().random)},
       )

       try:
              _SCREAMING_SNAKE_CASE  :						List[str]         =    (
                  BeautifulSoup(res.text, '''html.parser''')
                  .find('''div''', attrs={'''class''': '''yuRUbf'''})
                  .find('''a''')
                  .get('''href''')
              )

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

       webbrowser.open(link)





from collections.abc import Callable

import numpy as np
def        UpperCAmelCase_     (		_A   ,	_A   ,	_A   ,	_A   ,	_A       ):





     '''simple docstring'''




     SCREAMING_SNAKE_CASE__					=					int(np.ceil((x_end - xa) / step_size       )       )
     SCREAMING_SNAKE_CASE__					=					np.zeros((n + 1,)       )
     SCREAMING_SNAKE_CASE__					=					ya
     SCREAMING_SNAKE_CASE__					=					xa

     for k in range(_A       ):
          SCREAMING_SNAKE_CASE__					=					y[k] + step_size * ode_func(_A   ,	y[k]       )
          SCREAMING_SNAKE_CASE__					=					y[k] + (
              (step_size / 2) * (ode_func(_A   ,	y[k]       ) + ode_func(x + step_size   ,	_A       ))
          )
          x += step_size

     return y


if __name__ == "__main__":
       import doctest

       doctest.testmod()


