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 |
贴出代码,希望后面的同志一次过#include <stdio.h> #include <string.h> #include <ctype.h> int main() { char key[27]={0},input[100]={0}; gets(key); gets(input); for(int i=0;i<strlen(input);i++) { if(input[i]==' ') continue; if(isupper(input[i])) input[i]=toupper(key[input[i]-'A']); else input[i]=key[input[i]-'a']; } puts(input); return 0; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator