| Acme-BottomsUp documentation | view source | Contained in the Acme-BottomsUp distribution. |
Acme::BottomsUp - Write individual statements backwards
Version 0.02
my @arr = (1..10);
use Acme::BottomsUp;
@arr # first, start w/ numbers
grep { $_ % 2 } # then get the odd ones
map { $_**3 } # then cube each one
join ":", # and glue together
print # lastly, display result
;
print "ok";
no Acme::BottomsUp;
This module allows you to write multi-line perl statements in reverse order so that it "reads better". For example, normally one would write the code from the SYNOPSIS as:
my @arr = (1..10);
print # lastly, display result
join ":", # and glue together
map { $_**3 } # then cube each one
grep { $_ % 2 } # then get the odd ones
@arr # first, start with numbers
;
http://perlmonks.org/?node_id=567298 - Original location for RFC
David Westbrook (davidrw), <dwestbrook at gmail.com>
Please report any bugs or feature requests to
bug-acme-bottomsup at rt.cpan.org, or through the web interface at
http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Acme-BottomsUp.
I will be notified, and then you'll automatically be notified of progress on
your bug as I make changes.
I'm also available by email or via '/msg davidrw' on http://perlmonks.org.
You can find documentation for this module with the perldoc command.
perldoc Acme::BottomsUp
You can also look for information at:
Copyright 2006 David Westbrook, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
| Acme-BottomsUp documentation | view source | Contained in the Acme-BottomsUp distribution. |