in reply to Using getopt::Long

Yes, and Yes.

See also User defined subroutines to handle options