Reference variable by package name
#!/usr/bin/perl -w $main::name = "A"; $Tom::name = "B"; $Jack::name = "C"; print "\$name in package main is $name\n"; print "\$name in package Tom is $Tom::name\n"; print "\$name in package Jack is $Jack::name\n";