Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] recomendations for a functional language
- Date: Wed, 04 Nov 2009 20:17:02 +0900
- From: "Stephen J. Turnbull" <stephen@example.com>
- Subject: Re: [tlug] recomendations for a functional language
- References: <a63167770911010442pd642beco3268ed5c4a41d02@example.com> <20091102082821.GA28406@example.com> <a63167770911020112q1bd12b27ub5209902a971a6c9@example.com> <87hbtdtfch.fsf@example.com> <20091101131525.5f4312bd.attila@example.com> <20091102150646.GD16339@example.com> <20091103140253.7bf511a4.attila@example.com> <20091104060406.GE26028@example.com>
Curt Sampson writes: > implementations. (Scheme requires tail call optimization.) So that was > why I reckoned that CL encouraged looping rather than recursion, and why > I'm a little doubtful about Stephen's correction on that. But he would > probably know better than me. All I meant was what you said: the language you think in determines what you write. If you think in Lisp, you write recursive algorithms first, and then hand optimize to iteration if it matters. Scheme allows you to forget the second step. Eg, no Lisp textbook teaches you to write (defun factorial (n) (let ((result 0)) (loop for i from 1 to n do (setq result (* result i))))) it teaches you to write (defun factorial (n) (if (= n 1) n (* (factorial (1- n))))) > > > * the Lisp-1 versus Lisp-2 distinction (which can itself be > > > over-summarized as whether function variables and non-function > > > variables share a namespace, but upon research it turns out to be a > > > lot more subtle than that), > > > > What kind of subtilities? If you Google for "Lisp-1 Pitman Gabriel" you'll get a somewhat intelligible paper that explains all the ramifications of the difference for programming style.
- Follow-Ups:
- Re: [tlug] recomendations for a functional language
- From: Attila Kinali
- References:
- Re: [tlug] recomendations for a functional language
- From: Alan Busby
- Re: [tlug] recomendations for a functional language
- From: Curt Sampson
- Re: [tlug] recomendations for a functional language
- From: Alan Busby
- Re: [tlug] recomendations for a functional language
- From: Stephen J. Turnbull
- [tlug] recomendations for a functional language
- From: Attila Kinali
- Re: [tlug] recomendations for a functional language
- From: Curt Sampson
- Re: [tlug] recomendations for a functional language
- From: Attila Kinali
- Re: [tlug] recomendations for a functional language
- From: Curt Sampson
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] Pattern Matching
- Next by Date: Re: [tlug] Files copied to USB thumb drive completely gone
- Previous by thread: Re: [tlug] recomendations for a functional language
- Next by thread: Re: [tlug] recomendations for a functional language
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links