in reply to Reduce Redundant Repetition

Until Perl 6, you might find def -- Deal nicely with undefined values useful.     $targ= def( $opt_targ, 'localhost' );

        - tye (but my friends call me "Tye")