




"""simple docstring"""




def        a__					(							snake_case__			,					snake_case__							)		->   str:
			lowerCamelCase      =   [[] for _ in range(snake_case__							)]
			lowerCamelCase      =   key - 1

			if key <= 0:
						raise ValueError("""Height of grid can't be 0 or negative"""							)
			if key == 1 or len(snake_case__							) <= key:
						return input_string

			for position, character in enumerate(snake_case__							):
						lowerCamelCase      =   position % (lowest * 2)  # puts it in bounds
						lowerCamelCase      =   min(snake_case__			,					lowest * 2 - num							)  # creates zigzag pattern
						temp_grid[num].append(snake_case__							)
			lowerCamelCase      =   ["""""".join(snake_case__							) for row in temp_grid]
			lowerCamelCase      =   """""".join(snake_case__							)

			return output_string



def        a__					(							snake_case__			,					snake_case__							)		->   str:
			lowerCamelCase      =   []
			lowerCamelCase      =   key - 1

			if key <= 0:
						raise ValueError("""Height of grid can't be 0 or negative"""							)
			if key == 1:
						return input_string

			lowerCamelCase      =   [[] for _ in range(snake_case__							)]  # generates template
			for position in range(len(snake_case__							)							):
						lowerCamelCase      =   position % (lowest * 2)  # puts it in bounds
						lowerCamelCase      =   min(snake_case__			,					lowest * 2 - num							)  # creates zigzag pattern
						temp_grid[num].append("""*"""							)

			lowerCamelCase      =   0
			for row in temp_grid:  # fills in the characters
						lowerCamelCase      =   input_string[counter : counter + len(snake_case__							)]
						grid.append(list(snake_case__							)							)
						counter += len(snake_case__							)

			lowerCamelCase      =   """"""  # reads as zigzag
			for position in range(len(snake_case__							)							):
						lowerCamelCase      =   position % (lowest * 2)  # puts it in bounds
						lowerCamelCase      =   min(snake_case__			,					lowest * 2 - num							)  # creates zigzag pattern
						output_string += grid[num][0]
						grid[num].pop(0							)
			return output_string



def        a__					(							snake_case__							)		->   dict[int, str]:
			lowerCamelCase      =   {}
			for key_guess in range(1			,					len(snake_case__							)							):  # tries every key
						lowerCamelCase      =   decrypt(snake_case__			,					snake_case__							)
			return results


if __name__ == "__main__":
					import doctest

					doctest.testmod()









"""simple docstring"""




def        a__					(							snake_case__ = 10_00							)		->   int:
			lowerCamelCase ,  lowerCamelCase      =   1, 1
			lowerCamelCase      =   2
			while True:
						lowerCamelCase      =   0
						lowerCamelCase      =   fa + fa
						lowerCamelCase ,  lowerCamelCase      =   fa, f
						index += 1
						for _ in str(snake_case__							):
									i += 1
						if i == n:
									break
			return index


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



