Perl钻石操作符输入

前端之家收集整理的这篇文章主要介绍了Perl钻石操作符输入前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
1.[root@zsd script]# cat ex1_2.pl

2.#!/usr/bin/perl

3.while(<>){

4.        chomp;

5.        print "It was $_ that I saw!\n";

6.}

7.[root@zsd script]# cat fred

8.hello everyone

9.i see

10.sky is great player

11.[root@zsd script]# ./ex1_2.pl fred

12.It was hello everyone that I 

13.It was i see that I 

14.It was sky is great player that I 

15.[root@zsd script]#

猜你在找的Perl相关文章