



'''simple docstring'''




def      a      (			lowerCamelCase__ = 1_00_00_00   ):
			'''simple docstring'''





			A_     :						List[str]     =					1
			A_     :						Tuple     =					1
			A_     :						Any     =					{1: 1}

			for inputa in range(2						,				lowerCamelCase__   ):
						A_     :						Optional[Any]     =					0
						A_     :						Any     =					inputa

						while True:
									if number in counters:
												counter += counters[number]
												break
									if number % 2 == 0:
												number //= 2
												counter += 1
									else:
												A_     :						int     =					(3 * number) + 1
												counter += 1

						if inputa not in counters:
									A_     :						Optional[Any]     =					counter

						if counter > pre_counter:
									A_     :						Dict     =					inputa
									A_     :						List[Any]     =					counter
			return largest_number


if __name__ == "__main__":
						print(solution(int(input().strip())))




'''simple docstring'''




from typing import TYPE_CHECKING

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


lowerCamelCase							:Dict       = {'''configuration_mmbt''': ['''MMBTConfig''']}

try:
						if not is_torch_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						lowerCamelCase							:str       = ['''MMBTForClassification''', '''MMBTModel''', '''ModalEmbeddings''']


if TYPE_CHECKING:
						from .configuration_mmbt import MMBTConfig

						try:
												if not is_torch_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_mmbt import MMBTForClassification, MMBTModel, ModalEmbeddings

else:
						import sys

						lowerCamelCase							:Tuple       = _LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)