





'''simple docstring'''







from __future__ import annotations

import math
import random
from collections.abc import Collection
from typing import overload
class 				__SCREAMING_SNAKE_CASE  :






				"""simple docstring"""







				def __init__(  self     :					Any					,				__a     :					Collection[float] | None = None					):
								if components is None:
												_a								= []
								_a								= list(__a					)




				def __len__(  self     :					List[str]					):
								return len(self.__components					)




				def __str__(  self     :					List[str]					):
								return "(" + ",".join(map(__a					,				self.__components					)					) + ")"




				def __add__(  self     :					str					,				__a     :					Vector					):
								_a								= len(self					)
								if size == len(__a					):
												_a								= [self.__components[i] + other.component(__a					) for i in range(__a					)]
												return Vector(__a					)
								else:
												raise Exception("must have the same size"					)




				def __sub__(  self     :					str					,				__a     :					Vector					):
								_a								= len(self					)
								if size == len(__a					):
												_a								= [self.__components[i] - other.component(__a					) for i in range(__a					)]
												return Vector(__a					)
								else:  # error case
												raise Exception("must have the same size"					)




				@overload
				def __mul__(  self     :					str					,				__a     :					float					):
								...




				@overload
				def __mul__(  self     :					Dict					,				__a     :					Vector					):
								...




				def __mul__(  self     :					List[str]					,				__a     :					float | Vector					):
								if isinstance(__a					,				(float, int)					):
												_a								= [c * other for c in self.__components]
												return Vector(__a					)
								elif isinstance(__a					,				__a					) and len(self					) == len(__a					):
												_a								= len(self					)
												_a								= [self.__components[i] * other.component(__a					) for i in range(__a					)]
												return sum(__a					)
								else:  # error case
												raise Exception("invalid operand!"					)




				def   UpperCamelCase__   (  self     :					Tuple					):
								return Vector(self.__components					)




				def   UpperCamelCase__   (  self     :					List[str]					,				__a     :					int					):
								if isinstance(__a					,				__a					) and -len(self.__components					) <= i < len(self.__components					):
												return self.__components[i]
								else:
												raise Exception("index out of range"					)




				def   UpperCamelCase__   (  self     :					List[Any]					,				__a     :					int					,				__a     :					float					):
								assert -len(self.__components					) <= pos < len(self.__components					)
								_a								= value




				def   UpperCamelCase__   (  self     :					Union[str, Any]					):
								if len(self.__components					) == 0:
												raise Exception("Vector is empty"					)
								_a								= [c**2 for c in self.__components]
								return math.sqrt(sum(__a					)					)




				def   UpperCamelCase__   (  self     :					Optional[Any]					,				__a     :					Vector					,				__a     :					bool = False					):
								_a								= self * other
								_a								= self.euclidean_length() * other.euclidean_length()
								if deg:
												return math.degrees(math.acos(num / den					)					)
								else:
												return math.acos(num / den					)






def  _lowerCamelCase				( lowercase						:      int						)	->	Vector:
				assert isinstance(lowercase    ,							lowercase						)
				return Vector([0] * dimension						)






def  _lowerCamelCase				( lowercase						:      int    ,							lowercase						:      int						)	->	Vector:
				assert isinstance(lowercase    ,							lowercase						) and (isinstance(lowercase    ,							lowercase						))
				_a								= [0] * dimension
				_a								= 1
				return Vector(lowercase						)






def  _lowerCamelCase				( lowercase						:      float    ,							lowercase						:      Vector    ,							lowercase						:      Vector						)	->	Vector:
				assert (
				    isinstance(lowercase    ,							lowercase						)
				    and isinstance(lowercase    ,							lowercase						)
				    and (isinstance(lowercase    ,							(int, float)						))
				)
				return x * scalar + y






def  _lowerCamelCase				( lowercase						:      int    ,							lowercase						:      int    ,							lowercase						:      int						)	->	Vector:
				random.seed(lowercase						)
				_a								= [random.randint(lowercase    ,							lowercase						) for _ in range(lowercase						)]
				return Vector(lowercase						)
class 				__SCREAMING_SNAKE_CASE  :






				"""simple docstring"""







				def __init__(  self     :					Dict					,				__a     :					list[list[float]]					,				__a     :					int					,				__a     :					int					):
								_a								= matrix
								_a								= w
								_a								= h




				def __str__(  self     :					Tuple					):
								_a								= ""
								for i in range(self.__height					):
												ans += "|"
												for j in range(self.__width					):
																if j < self.__width - 1:
																				ans += str(self.__matrix[i][j]					) + ","
																else:
																				ans += str(self.__matrix[i][j]					) + "|\n"
								return ans




				def __add__(  self     :					str					,				__a     :					Matrix					):
								if self.__width == other.width() and self.__height == other.height():
												_a								= []
												for i in range(self.__height					):
																_a								= [
																    self.__matrix[i][j] + other.component(__a					,				__a					)
																    for j in range(self.__width					)
																]
																matrix.append(__a					)
												return Matrix(__a					,				self.__width					,				self.__height					)
								else:
												raise Exception("matrix must have the same dimension!"					)




				def __sub__(  self     :					List[Any]					,				__a     :					Matrix					):
								if self.__width == other.width() and self.__height == other.height():
												_a								= []
												for i in range(self.__height					):
																_a								= [
																    self.__matrix[i][j] - other.component(__a					,				__a					)
																    for j in range(self.__width					)
																]
																matrix.append(__a					)
												return Matrix(__a					,				self.__width					,				self.__height					)
								else:
												raise Exception("matrices must have the same dimension!"					)




				@overload
				def __mul__(  self     :					Dict					,				__a     :					float					):
								...




				@overload
				def __mul__(  self     :					Optional[Any]					,				__a     :					Vector					):
								...




				def __mul__(  self     :					List[Any]					,				__a     :					float | Vector					):
								if isinstance(__a					,				__a					):  # matrix-vector
												if len(__a					) == self.__width:
																_a								= zero_vector(self.__height					)
																for i in range(self.__height					):
																				_a								= [
																				    self.__matrix[i][j] * other.component(__a					)
																				    for j in range(self.__width					)
																				]
																				ans.change_component(__a					,				sum(__a					)					)
																return ans
												else:
																raise Exception(
																    "vector must have the same size as the "
																    "number of columns of the matrix!"					)
								elif isinstance(__a					,				(int, float)					):  # matrix-scalar
												_a								= [
												    [self.__matrix[i][j] * other for j in range(self.__width					)]
												    for i in range(self.__height					)
												]
												return Matrix(__a					,				self.__width					,				self.__height					)
								return None




				def   UpperCamelCase__   (  self     :					List[Any]					):
								return self.__height




				def   UpperCamelCase__   (  self     :					Optional[Any]					):
								return self.__width




				def   UpperCamelCase__   (  self     :					Tuple					,				__a     :					int					,				__a     :					int					):
								if 0 <= x < self.__height and 0 <= y < self.__width:
												return self.__matrix[x][y]
								else:
												raise Exception("change_component: indices out of bounds"					)




				def   UpperCamelCase__   (  self     :					Optional[Any]					,				__a     :					int					,				__a     :					int					,				__a     :					float					):
								if 0 <= x < self.__height and 0 <= y < self.__width:
												_a								= value
								else:
												raise Exception("change_component: indices out of bounds"					)




				def   UpperCamelCase__   (  self     :					Optional[Any]					,				__a     :					int					,				__a     :					int					):
								if self.__height != self.__width:
												raise Exception("Matrix is not square"					)
								_a								= self.__matrix[:x] + self.__matrix[x + 1 :]
								for i in range(len(__a					)					):
												_a								= minor[i][:y] + minor[i][y + 1 :]
								return Matrix(__a					,				self.__width - 1					,				self.__height - 1					).determinant()




				def   UpperCamelCase__   (  self     :					Tuple					,				__a     :					int					,				__a     :					int					):
								if self.__height != self.__width:
												raise Exception("Matrix is not square"					)
								if 0 <= x < self.__height and 0 <= y < self.__width:
												return (-1) ** (x + y) * self.minor(__a					,				__a					)
								else:
												raise Exception("Indices out of bounds"					)




				def   UpperCamelCase__   (  self     :					List[Any]					):
								if self.__height != self.__width:
												raise Exception("Matrix is not square"					)
								if self.__height < 1:
												raise Exception("Matrix has no element"					)
								elif self.__height == 1:
												return self.__matrix[0][0]
								elif self.__height == 2:
												return (
												    self.__matrix[0][0] * self.__matrix[1][1]
												    - self.__matrix[0][1] * self.__matrix[1][0]
												)
								else:
												_a								= [
												    self.__matrix[0][y] * self.cofactor(0					,				__a					) for y in range(self.__width					)
												]
												return sum(__a					)






def  _lowerCamelCase				( lowercase						:      int						)	->	Matrix:
				_a								= [[0] * n for _ in range(lowercase						)]
				return Matrix(lowercase    ,							lowercase    ,							lowercase						)






def  _lowerCamelCase				( lowercase						:      int    ,							lowercase						:      int    ,							lowercase						:      int    ,							lowercase						:      int						)	->	Matrix:
				random.seed(lowercase						)
				_a								= [
				    [random.randint(lowercase    ,							lowercase						) for _ in range(lowercase						)] for _ in range(lowercase						)
				]
				return Matrix(lowercase    ,							lowercase    ,							lowercase						)







'''simple docstring'''







def  _lowerCamelCase				( lowercase						:      int = 100						)	->	int:
				_a								= 0
				_a								= 0
				for i in range(1    ,							n + 1						):
								sum_of_squares += i**2
								sum_of_ints += i
				return sum_of_ints**2 - sum_of_squares


if __name__ == "__main__":
					print(f"""{solution() = }""")
