Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Transform Sequence Problem

by wbirkett (Novice)
on Jun 19, 2013 at 11:45 UTC ( #1039758=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    
    use B::Deparse;
    ...
    
    print "@out\n";
    
  2. or download this
    # some code references
    $f1 = sub {map {$_ + 1} @_};
    $f2 = sub {map {log($_)} @_};
    $f3 = sub {map {$_ * 3} @_};
    
  3. or download this
     # combined transform
    sub trans1 {&$f3(&$f2(&$f1))};
    
    ...
    @trans = trans1(@data);
    
    print "@trans\n";
    
  4. or download this
    # make a sequence array
    @seq = ($f1, $f2, $f3);
    ...
    @trans = trans2(@data);
    
    print "@trans\n";
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1039758]
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (7)
As of 2014-12-20 08:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (95 votes), past polls