






from __future__ import annotations
class  lowerCAmelCase_       :




							def __init__(   self     :   Any ,							SCREAMING_SNAKE_CASE_     :   int	):
											lowerCAmelCase__      			=						data
											lowerCAmelCase__      			=						None
											lowerCAmelCase__      			=						None





def 	lowerCAmelCase_		(lowercase__						:       Node | None       )		->    None:  # In Order traversal of the tree


				'''simple docstring'''




				if tree:
								display(tree.left       )
								print(tree.data       )
								display(tree.right       )





def 	lowerCAmelCase_		(lowercase__						:       Node | None       )		->    int:


				'''simple docstring'''




				return 1 + max(depth_of_tree(tree.left       )     ,					depth_of_tree(tree.right       )       ) if tree else 0





def 	lowerCAmelCase_		(lowercase__						:       Node       )		->    bool:


				'''simple docstring'''




				if not tree:
								return True
				if tree.left and tree.right:
								return is_full_binary_tree(tree.left       ) and is_full_binary_tree(tree.right       )
				else:
								return not tree.left and not tree.right





def 	lowerCAmelCase_		()		->    None:  # Main function for testing.


				'''simple docstring'''




				lowerCAmelCase__      			=						Node(1       )
				lowerCAmelCase__      			=						Node(2       )
				lowerCAmelCase__      			=						Node(3       )
				lowerCAmelCase__      			=						Node(4       )
				lowerCAmelCase__      			=						Node(5       )
				lowerCAmelCase__      			=						Node(6       )
				lowerCAmelCase__      			=						Node(7       )
				lowerCAmelCase__      			=						Node(8       )
				lowerCAmelCase__      			=						Node(9       )

				print(is_full_binary_tree(lowercase__       )       )
				print(depth_of_tree(lowercase__       )       )
				print('''Tree is: '''       )
				display(lowercase__       )


if __name__ == "__main__":
			main()













from typing import TYPE_CHECKING

from ....utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


_UpperCAmelCase			:		Optional[Any]   				=    {
    "configuration_mctct": ["MCTCT_PRETRAINED_CONFIG_ARCHIVE_MAP", "MCTCTConfig"],
    "feature_extraction_mctct": ["MCTCTFeatureExtractor"],
    "processing_mctct": ["MCTCTProcessor"],
}


try:
			if not is_torch_available():
						raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
			pass
else:
			_UpperCAmelCase			:		str   				=    [
			    "MCTCT_PRETRAINED_MODEL_ARCHIVE_LIST",
			    "MCTCTForCTC",
			    "MCTCTModel",
			    "MCTCTPreTrainedModel",
			]


if TYPE_CHECKING:
			from .configuration_mctct import MCTCT_PRETRAINED_CONFIG_ARCHIVE_MAP, MCTCTConfig
			from .feature_extraction_mctct import MCTCTFeatureExtractor
			from .processing_mctct import MCTCTProcessor

			try:
						if not is_torch_available():
									raise OptionalDependencyNotAvailable()
			except OptionalDependencyNotAvailable:
						pass
			else:
						from .modeling_mctct import MCTCT_PRETRAINED_MODEL_ARCHIVE_LIST, MCTCTForCTC, MCTCTModel, MCTCTPreTrainedModel

else:
			import sys

			_UpperCAmelCase			:		List[str]   				=    _LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)





