in reply to using a variable with require

See require for the full story. The short version is you need to replace :: with / and append a .pm

my $modName = 'Getopt/Long.pm'; require $modName;

Update Oops, this just answers the easy part of the question! Still thinking about the second part.

Optimising for fewest key strokes only makes sense transmitting to Pluto or beyond