A printable version of this contest can be found here.
What is the thing that...
So, what is it at all? The answer is in the sample I/O.
Given a word that is only composed of upper-case letters, please determine the length of the longest consecutive increasing letter string. A line contains only a character '#' indicating EOF, don’t proceed it.
Each line contains a word composed of upper-case letters except the last line, containing a single character '#'. All lengths of words are no more then 1,000,000 characters.
For each word output a single line containing a number.
AFGHANISTAN TAJIKISTAN STUDENT TEACHER FIRST SECOND #
3 2 3 1 3 1
Migrated from old NTUJ.
Tmt
No. | Testdata Range | Score |
---|