一、
import os
import sys
def dps(s):
dp = [0] * len(s)
dp[0] = ord(s[0]) - 96
if len(s) == 1:
return dp[-1]
dp[1] = max(ord(s[0]) - 96, ord(s[1]) - 96)
for i in range(2, len(s)):
dp[i] = max(dp[i - 1], dp[i - 2] + (ord(s[i])) - 96)
return dp[-1]
s = input()
print(dps(s))