UVA 10082
#include<iostream> #include<cstring> using namespace std; char a[100]="`1234567890-=QWERTYUIOP[]\\ASDFGHJKL;'ZXCVBNM,./"; int main() { char ch[1000]; while(cin.getline(ch,1000)) { for(int i=0;i<strlen(ch);i++) { if(isgraph(ch[i])&&!isdigit(ch[i])) { char *p; p=strchr(a,ch[i]); cout<<a[p-a-1]; } else cout<<ch[i]; } memset(ch,0,sizeof(ch)); cout<<endl; } return 0; }