Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
为啥老是wa啊?#include <iostream> #include <string> #include <cstdio> using namespace std; int main() { string sbegin,send; char letter[300]; int len; while(cin >> sbegin && sbegin != "ENDOFINPUT") { gets(letter); len = strlen(letter); for(int i=0; i<len; ++i) { if(letter[i] <= 90 && letter[i] >= 65) { letter[i] -= 5; if(letter[i] < 65) { letter[i] += 26; } } } cin >> send; cout << letter << endl; } return 0; } Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator