http://qs1969.pair.com?node_id=568262


in reply to Re^3: What I Most Recently Learned in Perl, But Should Have Already Known
in thread What I Most Recently Learned in Perl, But Should Have Already Known

I think this way is prettier.

sub do_something { my ($function) = @_; $function = 'default' unless exists $functions{$function}; $functions{$function}->(); }

Igor 'izut' Sutton
your code, your rules.

  • Comment on Re^4: What I Most Recently Learned in Perl, But Should Have Already Known
  • Download Code