hdu 1062
来源:互联网 发布:用js触发a标签的href 编辑:程序博客网 时间:2024/05/16 09:29
Ignatius likes to write words in reverse way. Given a single line of text which is written by Ignatius, you should reverse all the words and then output them.
Input
The input contains several test cases. The first line of the input is a single integer T which is the number of test cases. T test cases follow.
Each test case contains a single line with several words. There will be at most 1000 characters in a line.
Each test case contains a single line with several words. There will be at most 1000 characters in a line.
Output
For each test case, you should output the text which is processed.
Sample Input
3olleh !dlrowm'I morf .udhI ekil .mca
Sample Output
hello world!I'm from hdu.I like acm.HintRemember to use getchar() to read '\n' after the interger T, then you may use gets() to read a line and process it.
题意:输入一个字符串,将字符串中的 单词反转后输出,一次反转一个。
思路:先列读取进行的位数,随后for循环内进行反转与输出。
批:关键点未理顺,回车是进行下一项的标志未看到,所以不应用回车。
思路:使用str【i】【1000】模式,将之存入,随后
0 0
- HDU 1062
- HDU 1062
- HDU 1062
- HDU-1062
- hdu 1062
- HDU 1062
- HDU 1062
- HDU-1062
- Hdu 1062
- hdu 1062
- hdu 1062 Text Reverse
- hdu 1062 Text Reverse
- HDU 1062 TEXT REVERSE
- Hdu 1062 - Text Reverse
- hdu 1062 Text Reverse
- HDU 1062 Text Reverse
- hdu 1062 Text Reverse
- hdu 1062 字符串处理
- Maven实战(八)——常用Maven插件介绍(下)
- broker
- java固定种子随机数预测
- [BZOJ3209]花神的数论题
- Failed to create the host-only adapte
- hdu 1062
- SVN回退到历史版本
- IOS项目上架流程
- C++ 静态全局变量与普通全局变量
- java.io.IOException: Stream closed解决办法
- Ubuntu14.04安装GNOME3桌面
- vs2012 应用程序无法正常启动 (0xc0150002)
- JAXP(Java API for XMLProcessing)知识总结
- 冒泡排序