topcoder SRM 618 DIV2 WritingWords
时间:2014-06-17 14:02:13
收藏:0
阅读:386
只需要对word遍历一遍即可
int write(string word) { int cnt = 0; for(int i = 0 ; i < word.length(); ++ i){ cnt+=word[i]-‘A‘+1; } return cnt; }
topcoder SRM 618 DIV2 WritingWords,布布扣,bubuko.com
原文:http://www.cnblogs.com/xiongqiangcs/p/3791572.html
评论(0)