






"""simple docstring"""
from __future__ import annotations

import numpy as np






def 			__UpperCamelCase	(		snake_case__					):
	A_		:						Union[str, Any]	    =   np.shape(snake_case__					)
	if rows != columns:
		A_		:						List[Any]	    =   (
		    """'table' has to be of square shaped array but got a """
		    F"""{rows}x{columns} array:\n{table}"""
		)
		raise ValueError(snake_case__					)

	A_		:						List[str]	    =   np.zeros((rows, columns)					)
	A_		:						Union[str, Any]	    =   np.zeros((rows, columns)					)
	for i in range(snake_case__					):
		for j in range(snake_case__					):
			A_		:						List[Any]	    =   sum(lower[i][k] * upper[k][j] for k in range(snake_case__					)					)
			if upper[j][j] == 0:
				raise ArithmeticError("""No LU decomposition exists"""					)
			A_		:						List[str]	    =   (table[i][j] - total) / upper[j][j]
		A_		:						List[Any]	    =   1
		for j in range(snake_case__   ,   snake_case__					):
			A_		:						Union[str, Any]	    =   sum(lower[i][k] * upper[k][j] for k in range(snake_case__					)					)
			A_		:						Optional[int]	    =   table[i][j] - total
	return lower, upper


if __name__ == "__main__":
							import doctest

							doctest.testmod()









"""simple docstring"""
import sys
import webbrowser

import requests
from bsa import BeautifulSoup
from fake_useragent import UserAgent

if __name__ == "__main__":
							print("Googling.....")
							_lowerCAmelCase         =							"https://www.google.com/search?q=" + " ".join(sys.argv[1:])
							_lowerCAmelCase         =							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)
							_lowerCAmelCase         =							BeautifulSoup(res.text, "html.parser")
							_lowerCAmelCase         =							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")}')

