



from __future__ import annotations


def A    (							__UpperCamelCase = 4       )    ->   list[list[int]]:
			A__	  =     abs(__UpperCamelCase       ) or 4
			return [[1 + x + y * row_size for x in range(__UpperCamelCase       )] for y in range(__UpperCamelCase       )]


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			return reverse_row(transpose(__UpperCamelCase       )       )
			# OR.. transpose(reverse_column(matrix))


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			return reverse_row(reverse_column(__UpperCamelCase       )       )
			# OR.. reverse_column(reverse_row(matrix))


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			return reverse_column(transpose(__UpperCamelCase       )       )
			# OR.. transpose(reverse_row(matrix))


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			A__	  =     [list(__UpperCamelCase       ) for x in zip(*__UpperCamelCase       )]
			return matrix


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			A__	  =     matrix[::-1]
			return matrix


def A    (							__UpperCamelCase       )    ->   list[list[int]]:
			A__	  =     [x[::-1] for x in matrix]
			return matrix


def A    (							__UpperCamelCase       )    ->   None:
			for i in matrix:
						print(*__UpperCamelCase       )


if __name__ == "__main__":
							SCREAMING_SNAKE_CASE__   			=   make_matrix()
							print('''\norigin:\n''')
							print_matrix(matrix)
							print('''\nrotate 90 counterclockwise:\n''')
							print_matrix(rotate_aa(matrix))

							SCREAMING_SNAKE_CASE__   			=   make_matrix()
							print('''\norigin:\n''')
							print_matrix(matrix)
							print('''\nrotate 180:\n''')
							print_matrix(rotate_aaa(matrix))

							SCREAMING_SNAKE_CASE__   			=   make_matrix()
							print('''\norigin:\n''')
							print_matrix(matrix)
							print('''\nrotate 270 counterclockwise:\n''')
							print_matrix(rotate_aaa(matrix))








'''simple docstring'''






from __future__ import annotations


def    _snake_case  (	A			)		->       bool:
							lowerCAmelCase__			  =      str(A			)
							return len(A			) == 9 and set(A			) == set('''123456789'''			)


def    _snake_case  (	)		->       int | None:
							for base_num in range(9999					,       4999					,       -1			):
														lowerCAmelCase__			  =      100002 * base_num
														if is_9_pandigital(A			):
																					return candidate

							for base_num in range(333					,       99					,       -1			):
														lowerCAmelCase__			  =      1002003 * base_num
														if is_9_pandigital(A			):
																					return candidate

							return None


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