Keep It Simple, Stupid | |
PerlMonks |
Re: Re: Efficiency in maintenance coding...by eduardo (Curate) |
on Nov 15, 2001 at 22:09 UTC ( [id://125635]=note: print w/replies, xml ) | Need Help?? |
Hmmm. Another look what I can do in two lines discussion. I've been in quite a few of these so let me toss in something that might be a little different. no. not quite. the purpose of my original node was not that by a long shot. The purpose of my node was to discuss the relative complexity between VHLLs and more "systems" languages, especially as related to maintenance programming. To be honset, I am a little bit distressed that it was taken to be a "language wars" node, because I can guarantee you, that was *not* the intent. First up, you have picked one of perls strongest features to beat one of Java's weakest. If you compared opening a window and displaying a list of selections, I think I know which language would come out ahead. I am afraid I am going to have to disagree with this point. Currently, for a living, I am a maintenance java developer, working on an AWT application, so I do know the inner workings of managing UI's. Quite frankly, I do not find that the AWT or Swing would provide a clearer more concise, easier to maintain example than say, Tk, or Win32, or any of the other modules. I agree that the comparison would not be so drastic, but I think the languages would end up roughly "even." I do however believe that the code that would be required to grab, process, and understand the data that was put in to one of these "lists of selections" would probably be considerably easier in a VHLL. I do not have time right now to work up a small example, however tonight I may create an AWT example, a PerlTK example, and for fun a Python Win32 example... (or I may forget about this and have a fun night away from "the machine" :) As for everything else, yes... one of the greatest values of Perl *is* the community there is no doubt of that. And one of the greatest things the community has created *is* CPAN. However, the code that I showed used *no* CPAN modules, it used the inner expressiveness of the language. That's the incredible thing... Larry Wall (and those around him) worked very hard to create a language that is *expressive*, not because it has a wonderful class library (although it does), not because we have TheDamian or merlyn or Larry... but because the *language*, as a VHLL, allows me to *express* my program efficiently, without the overwhelming propegation of variables and constructs that create a supporting scaffolding for the *actual* task at hand... a problem that I see *every single day* on production Java code from dozens of different sources. My node happened to be on Perlmonks, and it happened to show 2 (as tilly showed via maintenance coding) poor lines of Perl code. However, this node could have been at ISETLmonks or PythonMonks or RubyMonks, or any of the hundreds of other languages which allow the programmer the freedom to *express* their software, rather than mechanically dictate and regurgitate it. However given the amount of head kicking it takes to get people to use CGI and strict here at the monastery, I imagine you could never get Java developers to use other peoples classes. They'd always be whinging about how they could do it faster or one line less or something. Sounds kinda familiar actually... Well, you're never going to get all people everywhere to agree on the 100% right set of modules... and even when you give them good evidence as to why doing things a certain way leads to better results... sometimes they ignore you. Wouldn't it be nice to have them make these mistakes in a language that when *YOU* go to maintenance code behind them, because their code was flawed (as so many hand rolled solutions have a tendency to be), you can replace their cargo-cultness with a few concise, expressive, ideomatic, and well tested and understood lines of code (probably using a CPAN module or two)? :) I know that's a situation I'd much rather be in.
In Section
Meditations
|
|