perl中chomp的使用
来源:互联网 发布:管家婆数据库如何安装 编辑:程序博客网 时间:2024/05/22 06:44
在输入的过程中主义使用chomp才能够得到正确的结果
如下程序:
print "Please input an string and a number by order!\n";$the_string=<>;$the_numb=<>;print "The result is \n";print "$the_string"x"$the_numb";结果如下:
The result is mymymymymy这里的问题便是没有使用chomp引起的
如果加入chomp如下:
print "Please input an string and a number by order!\n";chomp($the_string=<>);chomp($the_numb=<>);print "The result is \n";print "$the_string"x"$the_numb";那么就会得到如下的结果:
The result is mymymymymy
- perl中chomp的使用
- Perl中chomp和chop的区别
- Perl中chomp和chop的区别
- Perl chomp使用
- Perl chomp使用
- Perl中chomp和chop
- Perl中chomp函数和chop函数的区别
- Perl中chomp和chop的区别介绍
- Perl 的 chomp 命令用法
- Perl chomp
- Perl chomp 操作
- 2 Perl - chomp 操作
- [Perl]chomp 和 $/
- Perl 之 chomp 用法
- chop() vs. chomp() of Perl
- perl chop和chomp函数
- chomp函数使用举例
- perl的格式化输出,顺便再提一下chomp的重要性
- 快排
- 软件设计文档要求
- Java程序员应该知道的10个调试技巧
- 为什么EXE文件出现了不该出现的“盾牌”
- C++this指针
- perl中chomp的使用
- 信息检索导论学习笔记(三) 词词典及容错式检索
- Codeforces-125D2A
- 成功的代价
- Android开发工具方法
- 游戏编程
- VC调用WinRAR压缩文件
- php-cgi占用cpu100%的一次排障之旅
- 特色时间