in reply to package question

They limit the scope of the package directive, since package names are lexically scoped.

The examples would work without it, as long as you remember to add package main; before the main part of your code.

-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.