system函数使用介绍
#!/usr/bin/perl -w
$stant=system("ls");
print "$stant\n";
$well=system "'date'";
print "three:$well\n-------------\n";
@hello=("echo","hello,world!");
system(@hello);
`` 也可以用的
一个简单的例子:
#!/usr/bin/perl -w
@a=`ls /root` ;
foreach ( @a ) {
print $_ ;
}
直接输出
print `ls /root`;




