



'''simple docstring'''

def     __UpperCamelCase					(				_lowercase,					_lowercase,					_lowercase,					_lowercase       )			->      int:
	return len_board * len_board_column * row + column







def     __UpperCamelCase					(				_lowercase,					_lowercase,					_lowercase,					_lowercase,					_lowercase,					_lowercase,					)			->      bool:

	if board[row][column] != word[word_index]:
		return False

	if word_index == len(_lowercase       ) - 1:
		return True

	_lowercase       :							Optional[Any]  	=		[(0, 1), (0, -1), (-1, 0), (1, 0)]
	_lowercase       :							int  	=		len(_lowercase       )
	_lowercase       :							Any  	=		len(board[0]       )
	for direction in traverts_directions:
		_lowercase       :							Union[str, Any]  	=		row + direction[0]
		_lowercase       :							str  	=		column + direction[1]
		if not (0 <= next_i < len_board and 0 <= next_j < len_board_column):
			continue

		_lowercase       :							int  	=		get_point_key(_lowercase,					_lowercase,					_lowercase,					_lowercase       )
		if key in visited_points_set:
			continue

		visited_points_set.add(_lowercase       )
		if exits_word(_lowercase,					_lowercase,					_lowercase,					_lowercase,					word_index + 1,					_lowercase       ):
			return True

		visited_points_set.remove(_lowercase       )

	return False







def     __UpperCamelCase					(				_lowercase,					_lowercase       )			->      bool:
	_lowercase       :							List[str]  	=		(
	    'The board should be a non empty matrix of single chars strings.'
	)

	_lowercase       :							Any  	=		len(_lowercase       )
	if not isinstance(_lowercase,					_lowercase       ) or len(_lowercase       ) == 0:
		raise ValueError(_lowercase       )

	for row in board:
		if not isinstance(_lowercase,					_lowercase       ) or len(_lowercase       ) == 0:
			raise ValueError(_lowercase       )

		for item in row:
			if not isinstance(_lowercase,					_lowercase       ) or len(_lowercase       ) != 1:
				raise ValueError(_lowercase       )

    # Validate word
	if not isinstance(_lowercase,					_lowercase       ) or len(_lowercase       ) == 0:
		raise ValueError(
		    'The word parameter should be a string of length greater than 0.'       )

	_lowercase       :							str  	=		len(board[0]       )
	for i in range(_lowercase       ):
		for j in range(_lowercase       ):
			if exits_word(
			    _lowercase,					_lowercase,					_lowercase,					_lowercase,					0,					{get_point_key(_lowercase,					_lowercase,					_lowercase,					_lowercase       )}       ):
				return True

	return False


if __name__ == "__main__":
		import doctest

		doctest.testmod()





'''simple docstring'''

from __future__ import annotations

import sys







def     __UpperCamelCase					(				_lowercase       )			->      int:
	if n < 0:
		raise ValueError('Negative arguments are not supported'       )
	return _fib(_lowercase       )[0]







def     __UpperCamelCase					(				_lowercase       )			->      tuple[int, int]:
	if n == 0:  # (F(0), F(1))
		return (0, 1)

	# F(2n) = F(n)[2F(n+1) − F(n)]
	# F(2n+1) = F(n+1)^2+F(n)^2
	_lowercase	,     _lowercase       :							List[str]  	=		_fib(n // 2       )
	_lowercase       :							Dict  	=		a * (b * 2 - a)
	_lowercase       :							Union[str, Any]  	=		a * a + b * b
	return (d, c + d) if n % 2 else (c, d)


if __name__ == "__main__":
		_A					:     Optional[Any]      =int(sys.argv[1])
		print(F'''fibonacci({n}) is {fibonacci(n)}''')
