HDU1048 - The Hardest Problem Ever (简单题)
来源:互联网 发布:刷空间访问量软件 编辑:程序博客网 时间:2024/05/02 02:35
题目链接
- 思路
- 代码
思路
一道简单的入门题,列出表,然后输入输出就行。不过最开始智商被压制了,漏掉了字母
代码
#include <cstring>#include <cstdio>using namespace std;int main(){ char table[250]; char text[1000]; table[0] = '\n'; for(int i=1; i<'A'; i++) table[i] = i; table['A'] = 'V'; table['B'] = 'W'; table['C'] = 'X'; table['D'] = 'Y'; table['E'] = 'Z'; for(int i='F'; i<='Z'; i++) table[i] = i-5; while(true) { gets(text); if(strcmp(text, "ENDOFINPUT")==0) break; else if(strcmp(text, "END")==0) ; else if(strcmp(text, "START")==0) ; else { int len = strlen(text); for(int i=0; i<=len; i++) printf("%c", table[text[i]]); } } return 0;}
0 0
- HDU1048 - The Hardest Problem Ever (简单题)
- HDU1048 The Hardest Problem Ever
- hdu1048 The Hardest Problem Ever
- HDU1048 The Hardest Problem Ever
- hdu1048 The Hardest Problem Ever
- HDU1048 The Hardest Problem Ever
- hdu1048 The Hardest Problem Ever
- hdu1048 The Hardest Problem Ever
- The Hardest Problem Ever(hdu1048字符串水题)
- hdu1048 The Hardest Problem Ever(C语言)
- HDU1048——The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- The Hardest Problem Ever
- Android Application的作用
- 什么是反向代理,如何区别反向与正向代理
- HTTP 301 跳转和302跳转的区别
- 多线程NSThread
- Android compile with 为空
- HDU1048 - The Hardest Problem Ever (简单题)
- "Python"学习笔记(四)(函数一)
- HDU 5115 Dire Wolf(区间DP)
- Eclipse+maven+mybatis
- 贪心算法
- 省赛结束了, 战争开始了
- JS获取当前对象大小以及屏幕分辨率等
- HDU5430-----Reflect
- HDU 5427-A problem of sorting(字符串处理)