【CODEFORCES】 A. Keyboard
来源:互联网 发布:河北移动网络助手 编辑:程序博客网 时间:2024/06/05 13:37
题解:水题,打两个表就行了。
#include <iostream>#include <cstdio>#include <cstring>using namespace std;char c,s[150];int r[30]={97,'v','x','s','w','d','f','g','u','h','j','k','n','b','i','o',97,'e','a','r','y','c','q','z','t',97}, l[30]={'s','n','v','f','r','g','h','j','o','k','l',';',',','m','p','[','w','t','d','y','i','b','e','c','u','x'};int main(){ scanf("%c",&c); if (c=='R') { scanf("%s",s); for (int i=0;i<strlen(s);i++) if (s[i]=='[') cout <<"p"; else if (s[i]==';') cout <<"l"; else if (s[i]==',') cout <<"m"; else if (s[i]=='.') cout <<","; else if (s[i]=='/') cout <<"."; else printf("%c",r[s[i]-97]); } if (c=='L') { scanf("%s",s); for (int i=0;i<strlen(s);i++) if (s[i]=='.') cout <<"/"; else if (s[i]==',') cout <<"."; else printf("%c",l[s[i]-97]); } return 0;}
0 0
- 【CODEFORCES】 A. Keyboard
- CodeForces 474A Keyboard
- codeforces 474A Keyboard
- Codeforces 474A Keyboard (水
- codeforces Round #474--A.Keyboard
- Codeforces 801A Vicious Keyboard
- CodeForces 801A Vicious Keyboard
- codeforces 801A Vicious Keyboard
- A. Keyboard Codeforces Round #271(div2)
- Codeforces Round #271 (Div. 2) A. Keyboard
- CodeForces 801A Vicious Keyboard 模拟
- A. Keyboard
- Codeforces Round #271 (Div. 2) --A Keyboard (暴力)
- Codeforces Round #409 (Div. 2) A. Vicious Keyboard
- A. Vicious Keyboard
- A. Vicious Keyboard codeforce
- A. Vicious Keyboard
- A. Vicious Keyboard
- JavaSocket通信
- BigDecimal简单计算器
- Number Sequence(kmp模板)
- Gas Station
- 汉诺塔 搬盘子 过程
- 【CODEFORCES】 A. Keyboard
- respondsToSelector的相关使用
- SSH远程登录和SCP拷贝
- MySQL插入效率改进
- 左边部分添加到右边
- 关于Div的宽度与高度的100%设定
- Linux/UNIX下 ssh-keygen 设置SSH无密码登录
- A017 物料价格
- 使用GSON解析json