Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // main.cpp
- // 長方體
- //
- // Created by Chris on 2017/5/11.
- // Copyright © 2017年 Chris. All rights reserved.
- //
- #include <iostream>
- #include <cstdlib>
- #include <math.h>
- #include <cstdio>
- #include <string>
- using namespace std;
- char st[] = "`1234567890-=QWERTYUIOP[]\\ASDFGHJKL;'ZXCVBNM,./";
- int main( ) {
- int c,i;
- while((c = getchar()) != EOF){
- for (i=1;st[i]&&st[i] != c;i++);
- if(st[i]) putchar(st[i-1]);
- else putchar(c);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement