code: 
  
  from __future__ import annotations
  
  from typing import Any
  
  
  
  def  _A  (			*SCREAMING_SNAKE_CASE			):
  	if all(_check_not_integer(SCREAMING_SNAKE_CASE			) for m in matrix_s			):
  		for i in matrix_s[1:]:
  			_verify_matrix_sizes(matrix_s[0]  ,SCREAMING_SNAKE_CASE			)
  		return [[sum(SCREAMING_SNAKE_CASE			) for t in zip(*SCREAMING_SNAKE_CASE			)] for m in zip(*SCREAMING_SNAKE_CASE			)]
  	raise TypeError("Expected a matrix, got int/list instead"			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			):
  	if (
  	    _check_not_integer(SCREAMING_SNAKE_CASE			)
  	    and _check_not_integer(SCREAMING_SNAKE_CASE			)
  	    and _verify_matrix_sizes(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			)
  	):
  		return [[i - j for i, j in zip(*SCREAMING_SNAKE_CASE			)] for m in zip(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			)]
  	raise TypeError("Expected a matrix, got int/list instead"			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			):
  	return [[x * n for x in row] for row in matrix]
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			):
  	if _check_not_integer(SCREAMING_SNAKE_CASE			) and _check_not_integer(SCREAMING_SNAKE_CASE			):
  		UpperCAmelCase__       ,	UpperCAmelCase__:  Optional[Any]		       =   _verify_matrix_sizes(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			)
  
  	if cols[0] != rows[1]:
  		UpperCAmelCase__:  Dict		       =   (
  		    "Cannot multiply matrix of dimensions "
  		    f"({rows[0]},{cols[0]}) and ({rows[1]},{cols[1]})"
  		)
  		raise ValueError(SCREAMING_SNAKE_CASE			)
  	return [
  	    [sum(m * n for m, n in zip(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			)			) for j in zip(*SCREAMING_SNAKE_CASE			)] for i in matrix_a
  	]
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	UpperCAmelCase__:  List[Any]		       =   int(SCREAMING_SNAKE_CASE			)
  	return [[int(row == column			) for column in range(SCREAMING_SNAKE_CASE			)] for row in range(SCREAMING_SNAKE_CASE			)]
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE = True			):
  	if _check_not_integer(SCREAMING_SNAKE_CASE			):
  		if return_map:
  			return map(SCREAMING_SNAKE_CASE  ,zip(*SCREAMING_SNAKE_CASE			)			)
  		else:
  			return list(map(SCREAMING_SNAKE_CASE  ,zip(*SCREAMING_SNAKE_CASE			)			)			)
  	raise TypeError("Expected a matrix, got int/list instead"			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			):
  	UpperCAmelCase__:  Optional[Any]		       =   matrix[:row] + matrix[row + 1 :]
  	return [row[:column] + row[column + 1 :] for row in minor]
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	if len(SCREAMING_SNAKE_CASE			) == 1:
  		return matrix[0][0]
  
  	return sum(
  	    x * determinant(minor(SCREAMING_SNAKE_CASE  ,0  ,SCREAMING_SNAKE_CASE			)			) * (-1) ** i
  	    for i, x in enumerate(matrix[0]			)			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	UpperCAmelCase__:  Any		       =   determinant(SCREAMING_SNAKE_CASE			)
  	if det == 0:
  		return None
  
  	UpperCAmelCase__:  Any		       =   [
  	    [determinant(minor(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			)			) for j in range(len(SCREAMING_SNAKE_CASE			)			)]
  	    for i in range(len(SCREAMING_SNAKE_CASE			)			)
  	]
  
  	UpperCAmelCase__:  Optional[int]		       =   [
  	    [x * (-1) ** (row + col) for col, x in enumerate(matrix_minor[row]			)]
  	    for row in range(len(SCREAMING_SNAKE_CASE			)			)
  	]
  	UpperCAmelCase__:  Union[str, Any]		       =   list(transpose(SCREAMING_SNAKE_CASE			)			)
  	return scalar_multiply(SCREAMING_SNAKE_CASE  ,1 / det			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	return not isinstance(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			) and not isinstance(matrix[0]  ,SCREAMING_SNAKE_CASE			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	return len(SCREAMING_SNAKE_CASE			), len(matrix[0]			)
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			):
  	UpperCAmelCase__:  str		       =   _shape(SCREAMING_SNAKE_CASE			) + _shape(SCREAMING_SNAKE_CASE			)
  	if shape[0] != shape[3] or shape[1] != shape[2]:
  		UpperCAmelCase__:  str		       =   (
  		    "operands could not be broadcast together with shape "
  		    f"({shape[0], shape[1]}), ({shape[2], shape[3]})"
  		)
  		raise ValueError(SCREAMING_SNAKE_CASE			)
  	return (shape[0], shape[2]), (shape[1], shape[3])
  
  
  
  def  _A  (			):
  	UpperCAmelCase__:  Optional[int]		       =   [[1_2, 1_0], [3, 9]]
  	UpperCAmelCase__:  List[str]		       =   [[3, 4], [7, 4]]
  	UpperCAmelCase__:  int		       =   [[1_1, 1_2, 1_3, 1_4], [2_1, 2_2, 2_3, 2_4], [3_1, 3_2, 3_3, 3_4], [4_1, 4_2, 4_3, 4_4]]
  	UpperCAmelCase__:  Union[str, Any]		       =   [[3, 0, 2], [2, 0, -2], [0, 1, 1]]
  	print(f"Add Operation, {add(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			) = } \n"			)
  	print(
  	    f"Multiply Operation, {multiply(SCREAMING_SNAKE_CASE  ,SCREAMING_SNAKE_CASE			) = } \n"  ,)
  	print(f"Identity: {identity(5			)}\n"			)
  	print(f"Minor of {matrix_c} = {minor(SCREAMING_SNAKE_CASE  ,1  ,2			)} \n"			)
  	print(f"Determinant of {matrix_b} = {determinant(SCREAMING_SNAKE_CASE			)} \n"			)
  	print(f"Inverse of {matrix_d} = {inverse(SCREAMING_SNAKE_CASE			)}\n"			)
  
  
  if __name__ == "__main__":
  					import doctest
  
  					doctest.testmod()
  					main()
style_context: 
  
  import numpy as np
  
  
  
  def  _A  (			SCREAMING_SNAKE_CASE			):
  	UpperCAmelCase__:  List[Any]		       =   np.exp(SCREAMING_SNAKE_CASE			)
  
  	# Add up the all the exponentials
  	UpperCAmelCase__:  str		       =   np.sum(SCREAMING_SNAKE_CASE			)
  
  	# Divide every exponent by the sum of all exponents
  	UpperCAmelCase__:  Tuple		       =   exponent_vector / sum_of_exponents
  
  	return softmax_vector
  
  
  if __name__ == "__main__":
  					print(softmax((0,)))