





import os






def 					SCREAMING_SNAKE_CASE__				(							):
		with open(os.path.dirname(UpperCamelCase__     ) + """/p022_names.txt"""     ) as file:
				SCREAMING_SNAKE_CASE__								=   str(file.readlines()[0]     )
				SCREAMING_SNAKE_CASE__								=   names.replace("""\""""       , """"""     ).split(""","""     )

		names.sort()

		SCREAMING_SNAKE_CASE__								=   0
		SCREAMING_SNAKE_CASE__								=   0

		for i, name in enumerate(UpperCamelCase__     ):
				for letter in name:
						name_score += ord(UpperCamelCase__     ) - 64

				total_score += (i + 1) * name_score
				SCREAMING_SNAKE_CASE__								=   0
		return total_score


if __name__ == "__main__":
	print(solution())






def 					SCREAMING_SNAKE_CASE__				(							UpperCamelCase__:				int = 600_851_475_143     ):

		try:
				SCREAMING_SNAKE_CASE__								=   int(UpperCamelCase__     )
		except (TypeError, ValueError):
				raise TypeError("""Parameter n must be int or castable to int."""     )
		if n <= 0:
				raise ValueError("""Parameter n must be greater than or equal to one."""     )
		SCREAMING_SNAKE_CASE__								=   1
		SCREAMING_SNAKE_CASE__								=   2
		while i * i <= n:
				while n % i == 0:
						SCREAMING_SNAKE_CASE__								=   i
						n //= i
				i += 1
		if n > 1:
				SCREAMING_SNAKE_CASE__								=   n
		return int(UpperCamelCase__     )


if __name__ == "__main__":
	print(F'''{solution() = }''')