in reply to Help required on Getopt::Long

This is because -help is treated as string for the option "abc". even though '=' is not used the next string is tied for "abc" option.

Also, when i executed this code, i got the following error:

Undefined subroutine &main::Getoptions called.

Always include use strict and use warnings in your code. And the subroutine should be GetOptions

Replies are listed 'Best First'.
Re^2: Help required on Getopt::Long
by Anonymous Monk on May 16, 2012 at 10:38 UTC
    read "Getoptions" as "GetOptions". Sorry for the typo.