加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 大数据 > 正文

perl command not found

发布时间:2020-12-15 23:52:41 所属栏目:大数据 来源:网络整理
导读:perl 脚本内容: #!/usr/bin/perl -wuse strict;use warnings;#use Data::Dumper;#use Storable;my $a = "good";print "$an"; 运行是发现如下错误: root@zctech-chengjb:/home/zczhangjx/智呈监控系统/perl# ./11.pl ./11.pl: line 3: use: command not fo

perl 脚本内容:

#!/usr/bin/perl -w
use strict;
use warnings;
#use Data::Dumper;
#use Storable;

my $a = "good";
print "$an";

运行是发现如下错误:

root@zctech-chengjb:/home/zczhangjx/智呈监控系统/perl# ./11.pl 
./11.pl: line 3: use: command not found
./11.pl: line 4: use: command not found
./11.pl: line 8: my: command not found
Warning: unknown mime-type for "n" -- using "application/octet-stream"
Error: no such file "n"
最后发现是脚本的开始是空行等,不是以
#!/usr/bin/perl
开头,因此报错,修改之后正常了:

root@zctech-chengjb:/home/zczhangjx/智呈监控系统/perl# ./11.pl 
good

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读