I'm寫我在Perl程序首先,寫下這樣的:爲什麼Perl說全局符號「SYMBOL」需要在PROGRAM.pl行X處顯式包名?
use strict;
use warnings;
$animal = "camel";
print($animal);
當我運行它,我從Windows命令行這些消息:
Global symbol "animal" requires explicit package name at stringanimal.pl line 3
Global symbol "animal" requires explicit package name at stringanimal.pl line 4
請,任何人都可以這些消息是什麼意思?
¿什麼是包裝? – Peterstone 2010-11-23 15:05:33