In below code I am checking if $options are defined or not, if not then i am assigning respective file name to variables but without defined it work but with defined i am getting 1 as a value for variable rather than actual value, Any suggestion?please,
my $source_file= defined($options{o}) || 'as.xcf-dist'; my $config_file= defined($options{c}) || 'config.ini'; my $dest_file= defined($options{x}) || usage();

In reply to question about getopt by Sun751

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":