Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re (tilly) 5: Efficiency in maintenance coding...

by tilly (Archbishop)
on Nov 15, 2001 at 04:55 UTC ( [id://125478]=note: print w/replies, xml ) Need Help??


in reply to Re (tilly) 3: Efficiency in maintenance coding...
in thread Efficiency in maintenance coding...

Perl.

Right now our Java solution hasn't yet figured out how to handle contractions yet. Perl is still ahead. Secondly why break out the sledgehammer when you don't have to?

foreach my $word ( sort { $freq_count{$b} <=> $freq_count{$a} or $a cmp $b } keys %freq_count ) { print "$word:\t$freq{$word}\n"; }
Most Perl programmers should understand this. Doing the same in Java, well probably somewhere in their maze of classes is one that naturally sorts in exactly the order you want. Good luck finding it, and good luck for the average Java programmer realizing why you chose this way of doing things.

And as for the maintainability of a Schwartzian Transform, it is a trick. If you think in a list-oriented way, or if you have ever really understood the tranform, then maintaining it when you see one is pretty easy. I understand it, and I try to ensure that people I train are able to handle list-oriented thinking. So it isn't a problem for me. But YMMV on its maintainability.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://125478]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (6)
As of 2024-04-24 12:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found