perl
cgjkjk
这个作者很懒,什么都没留下…
展开
-
Perl 函数原型
Perl函数原型的作用就是把用户自定义函数的调用方式变得像Perl系统函数一样。 下面是一个小例子; #!/usr/bin/perl -w use strict; sub func_protocol ( $$ ) { my ($my_1,$my_2) = @_ ; print $my_1,"\n" ; print $my_2,"\n" ; } func原创 2012-04-13 16:48:59 · 796 阅读 · 0 评论 -
What is \f ?
\f or ^L is called form feed or page break, to cause a printer to eject paper to the top of the next page, or a video terminal to clear the screen.转载 2012-04-23 13:17:08 · 503 阅读 · 0 评论 -
Perl操作符
这里列几个不常用的Perl操作符备忘。 $test ||=2; 如果$test的布尔值为false,就赋值为2 my $test3 ="abc"; $test3 x=3; 重复$test3的字符串3次,注意是x=,不是*=。 测试源码 #!/usr/bin/perl use Data::Dumper; my $test ||=2; my $test2 = 0; print Dum原创 2013-12-17 11:41:50 · 742 阅读 · 0 评论