If we define each of the upper case letters a number, that is, 1 for A, 2 for B, 3 for C, ... 25 for Y, 26 for Z, we can calculate a mark for any word or sentence.
We believe that 100 points is the full mark, so for those word with a mark larger than 100, we should just ignore that, with a label "INVALID". Then lets see interesting results:
What is the most important for your success?
So just be with good attitude and you will be on your way to success.
For each case of the input, it contains a single line. For each line, some characters will appear with maybe some of them being upper case letters. All characters are printable. Each line will have at most 127 characters.
For each case, you should only pay attention to upper case letters and calculate the total points. If it is over 100, "INVALID" should be returned. Or you should print the exact point of that.
DELICIOUS FOOD YY, and YY again! did i lose anything?
INVALID 100 0
Migrated from old NTUJ.
2009Harbin
No. | Testdata Range | Score |
---|