in reply to New Year's Resolution: learn another language

If you've never had any exposure to a Functional Programming language, now's a good time to take a look.

And if all the CS on that link is off-putting, it really is radically different from those things you've mentioned you've used to date, then take a look at The Q Language. I cannot thank the anonymonk that put me onto this a few months ago enough. It has really opened my eyes. And it is far easier to get into than most other FP langauges around.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."
  • Comment on Re: New Year's Resolution: learn another language

Replies are listed 'Best First'.
Re^2: New Year's Resolution: learn another language
by plobsing (Friar) on Jan 07, 2008 at 11:50 UTC
    I don't know that it would be that different. He mentioned knowledge of XSL. If he's done XSLT, then he would have been fighting the language pretty hard not to do so in a somewhat functional style.

      Having been forced to use XSLT for a short period some years ago, my initial reaction to your suggesting that it is an FP language was one of complete and utter disbelief. However, I googled and found several people making a similar suggestion.

      I have to say that I find it almost impossible to relate my experience of programming XSLT as anything like my experience of programming in any of several real FP languages. Indeed, I wouldn't wish XSLT upon anyone, not even my worst enemy. I see it has it's uses for performing a limited set of very specific types of transformations upon large volumes of XML encoded data, but as a general purpose programming language (IMO) it is a disaster.

      The analogy that comes to mind is: Given the increasingly powerful processors available in mobile phones, and combining them with the nearly ubiquitous presence of video-capable digital cameras, it would be possible to program them to allow you to type SMS texts by placing the phone on a work surface and using Semaphore. I have absolutely no doubts it could be done, but would anyone really use it?

      (IMO) XSLT is the absolute antithesis of FP. Just look at all the needlessly repetitive verbosity XSLT entails.

      And whilst it supports (after a fashion) high order functions, imagine trying to do the holy grail of FP: Fixed Point Combinators using XSLT?

      Aristotle demonstrated how to do the Y combinator in Perl a while back. Now compare that to the same thing in Q: _Y = \F.(\X.F '(X X)) (\X.F '(X X));

      If the Perl version is an order of magnitude more complex and verbose than the Q version, I can only imagine that the XSLT would be one order more complex and two orders more verbose than the Perl. That's if it is possible to do it at all. And IMO, that totally negates any claim that XSLT is a FP language.


      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority".
      In the absence of evidence, opinion is indistinguishable from prejudice.
        Surely you jest.

        Yes, XSLT is verbose and ugly. I find most XML to be that way. However, breadth of domain and verbosity levels do not indicate the style of a programming language.

        By definition, XSLT is Purely Functional. As I understand it purely functional languages are a strict subset of Functional Programming languages.

        If it helps, you can think of XSLT as the most dysfunctional functional language.