407127: GYM102697 098 It's More Fun To Compute

Memory Limit:256 MB Time Limit:1 S
Judge Style:Text Compare Creator:
Submit:0 Solved:0

Description

098. It's More Fun To Computetime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output

It's More Fun To Compute

You are trying to discover that it's more fun to compute, and you're doing so by evaluating long strings of text. You define the fun-ness of a string to be the amount of characters in the string that are equal to "f", "u", and "n". You can perform cyclic shifts on the string an infinite number of times. When you cyclically shift the string, each character changes into the one after it, so any "a" characters become "b", "b" becomes "c", etc. "z" characters turn into "a" in a cyclic shift.

Given that you can perform an infinite number of cyclic shifts on the input string, find the maximum fun-ness of the string.

Input

The only line of input contains a single string $$$s$$$, consisting of only lowercase a-z characters and spaces. (When you perform a cyclic shift on the string, nothing happens to the spaces).

Output

Output a single positive integer $$$n$$$: the maximum possible fun-ness of the string, as described above.

ExamplesInput
hello world
Output
5
Input
coderams contest number eight
Output
9

加入题单

上一题 下一题 算法标签: