use feature ":5.14"; use warnings FATAL => qw(all); use strict; use Data::Dump qw(dump); eval "sub $_ {say \"$_\"}" for qw(hello goodbye); hello(); goodbye(); __END__ Produces: hello goodbye
In reply to Re: a loop for creating subroutines?
by philiprbrenan
in thread a loop for creating subroutines?
by mascip
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |