Ross Werner wrote:
On Wed, 21 Apr 2004, Stuart Jansen wrote:


On Wed, 2004-04-21 at 23:00, Mac Newbold wrote:

Mac, who still cringes at the mention of the L*** word...

I enjoyed my foray into functional programming. Wish it were more widespread so I could use it more frequently.


I just can't figure out what it's _useful_ for. Seriously--with languages like Perl around, where you can do Lisp-ish sort of things, are there _any_ sorts of programs where the functional programming mindset/paradigm makes more sense and is eaier to program/debug/maintain than modern procedural languages?

Granted, my entire experience with Lisp/Scheme is CS330, which hopefully I just barely passed. But that was the question I was thinking of the whole semester ... what would functional programming be _useful_ for?

Any takers?

Well, well. Two posts from ex-Viscom employees in a matter of minutes. BTW, congrats on your engagement. :)



[Grant grunts as he steps up onto the functional programming soapbox]


In my opinion, functional programming can be extremely powerful. Or rather, the language features you get with most functional programming languages _are_ extremely powerful, allowing functional programming to reach a lofty peak. Specifically, the ability to create functions on the fly as either anonymous or named and return them from function calls opens new worlds of possibility. It could allow you to have a truly dynamic program. Let's say you have a text editor written in a language that supports "first class" functions. You could allow the user to change the function that gets called when doing searching so they could make a nice regular-expression search dialog. Don't like another feature of the program? Write a new one and swap it on the fly. For some crazy/cool examples of this, go check out Squeak[1]. So, new functions based on user input would be one powerful feature of first-class functions. Also, the ability to pass along true functions to methods is very cool as well. With a little bit of imagination, the features found in most functional languages can allow a lot of really elegant solutions to problems that would be difficult, if not impossible, to accomplish with C++ or Java.

Well, that's enough for now. Any other takers?

Grant


[1] http://www.squeak.org/


____________________
BYU Unix Users Group http://uug.byu.edu/ ___________________________________________________________________
List Info: http://uug.byu.edu/cgi-bin/mailman/listinfo/uug-list

Reply via email to