



import sys
import webbrowser

import requests
from bsa import BeautifulSoup
from fake_useragent import UserAgent

if __name__ == "__main__":
  print("""Googling.....""")
  a_								=       """https://www.google.com/search?q=""" + """ """.join(sys.argv[1:])
  a_								=       requests.get(url, headers={"""UserAgent""": UserAgent().random})
  # res.raise_for_status()
  with open("""project1a.html""", """wb""") as out_file:  # only for knowing the class
    for data in res.iter_content(10_000):
      out_file.write(data)
  a_								=       BeautifulSoup(res.text, """html.parser""")
  a_								=       list(soup.select(""".eZt8xd"""))[:5]

  print(len(links))
  for link in links:
    if link.text == "Maps":
      webbrowser.open(link.get("""href"""))
    else:
      webbrowser.open(f"https://google.com{link.get('href')}")











from typing import Callable, Optional

from .. import Features
from ..packaged_modules.generator.generator import Generator
from .abc import AbstractDatasetInputStream



class 			__lowerCAmelCase  (						lowerCAmelCase__ ):




 def __init__(    self						,					__UpperCAmelCase						,					__UpperCAmelCase = None						,					__UpperCAmelCase = None						,					__UpperCAmelCase = False						,					__UpperCAmelCase = False						,					__UpperCAmelCase = None						,					__UpperCAmelCase = None						,					**__UpperCAmelCase						,					):



    '''simple docstring'''
    super().__init__(
        features=__UpperCAmelCase						,					cache_dir=__UpperCAmelCase						,					keep_in_memory=__UpperCAmelCase						,					streaming=__UpperCAmelCase						,					num_proc=__UpperCAmelCase						,					**__UpperCAmelCase						,					)
    __lowerCamelCase    				=     Generator(
        cache_dir=__UpperCAmelCase						,					features=__UpperCAmelCase						,					generator=__UpperCAmelCase						,					gen_kwargs=__UpperCAmelCase						,					**__UpperCAmelCase						,					)




 def 							lowerCamelCase   (    self					):



    '''simple docstring'''
    # Build iterable dataset
    if self.streaming:
       __lowerCamelCase    				=     self.builder.as_streaming_dataset(split='''train'''					)
    # Build regular (map-style) dataset
    else:
       __lowerCamelCase    				=     None
       __lowerCamelCase    				=     None
       __lowerCamelCase    				=     None
       __lowerCamelCase    				=     None

       self.builder.download_and_prepare(
           download_config=__UpperCAmelCase						,					download_mode=__UpperCAmelCase						,					verification_mode=__UpperCAmelCase						,					base_path=__UpperCAmelCase						,					num_proc=self.num_proc						,					)
       __lowerCamelCase    				=     self.builder.as_dataset(
           split='''train'''						,					verification_mode=__UpperCAmelCase						,					in_memory=self.keep_in_memory					)
    return dataset






