题目链接如下:
我的代码如下:
#include <cstdio>
#include <string.h>
int main(){
const char s[] = "1234567890-=WERTYUIOP[]\\SDFGHJKL;'XCVBNM,./";
const char t[] = "`1234567890-QWERTYUIOP[]ASDFGHJKL;ZXCVBNM,.";
char c;
while((c = getchar()) != EOF){
if(strchr(s, c)){
printf("%c", t[strchr(s, c) - s]);
} else{
printf("%c", c);
}
}
return 0;
}