






"""simple docstring"""



def      _lowerCAmelCase		(							UpperCAmelCase__       :					Optional[int],						UpperCAmelCase__       :					List[Any] = 0      )		->Dict:
						A__						:  List[str]		  =  length or len(_lowerCamelCase      )
						A__						:  str		  =  False
						for i in range(length - 1      ):
												if list_data[i] > list_data[i + 1]:
																		A__						:  Optional[Any]		  =  list_data[i + 1], list_data[i]
																		A__						:  List[Any]		  =  True

						return list_data if not swapped else bubble_sort(_lowerCamelCase,						length - 1      )


if __name__ == "__main__":
						import doctest

						doctest.testmod()














"""simple docstring"""



def      _lowerCAmelCase		(							UpperCAmelCase__       :					int = 1_0_0_0      )		->int:
						A__						:  Optional[int]		  =  2**power
						A__						:  Dict		  =  0
						while n:
												A__  ,  A__						:  Tuple		  =  r + n % 1_0, n // 1_0
						return r


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






