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


in reply to Re: Subroutine chaining idiom requested
in thread Subroutine chaining idiom requested

Did someone say golf?
sub chain{(*f,*_)=@_;@_=&$_ for@f;@_}
Of course you probably want strict compliant and it is bad style to modify your arguments in place. In which case it is probably better to make that:
sub chain{my($f,$a)=@_;$a=[&$_(@$a)]for@$f;@$a}
which is still reasonable...