Perl subs nearly all handle any number of arguments, passed in as aliases in @_. Perl has printf which works just like the C function.
sub printf_like { my ($fmt, $flag) = (shift(), 1); printf $fmt, $_ or $flag = 0 for @_; return $flag; }
After Compline,
Zaxo
In reply to Re: How to implement printf like functions
by Zaxo
in thread How to implement printf like functions
by kamesh3183
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |