(self, arg: list[list] | int)
| 12 | |
| 13 | class Matrix: |
| 14 | def __init__(self, arg: list[list] | int) -> None: |
| 15 | if isinstance(arg, list): # Initializes a matrix identical to the one provided. |
| 16 | self.t = arg |
| 17 | self.n = len(arg) |
| 18 | else: # Initializes a square matrix of the given size and set values to zero. |
| 19 | self.n = arg |
| 20 | self.t = [[0 for _ in range(self.n)] for _ in range(self.n)] |
| 21 | |
| 22 | def __mul__(self, b: Matrix) -> Matrix: |
| 23 | matrix = Matrix(self.n) |
nothing calls this directly
no outgoing calls
no test coverage detected