From: Eric Hodel Date: 2002-12-12T04:06:48+09:00 Subject: Re: functional programming "style" --DheUW4aQn8WJk6WR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable zesar (i_wont@tell.you) wrote: > i discovered ruby some weeks ago and i have to say now that i'm through w= ith > the book of the pragmatic programmers i quite like the language. >=20 > so far i've been coding in c/c++, java and COBOL (that was really painful > :) )... i guess that's why my code keeps on looking very procedural altho= ugh > i'm writing ruby. >=20 > i'm very fascinated by the few examples of functional programming-style i= 've > seen so far but i don't quite get the picture on how to "think this way".= .. > i mean i DO understand what the examples do and mean but i wouldn't be ab= le > to write them myself... >=20 > i know there are some other (more) functional languages than ruby but i > don't have the energy nor the time to learn them. and i just want to get a > good coding style in ruby... >=20 > the book of the pragmatic programmers is a very good reference but i lack > some sort of > think-styleguide-on-functional-programming-for-procedural-programmers or > something likewise... or is there just some kind of "magic sentence" - a > "spell" ;-)) that can teach me how to.... >=20 > anyway, i'd love to get some tips or some recommendations where to find s= uch > a guide (hopefully there's a free one, i don't like buying books for i do= n't > really have the money - but don't hesitate to recommend a book - better t= han > nothing)... I'd recommend checking out 'The Little Schemer' or 'The Little Lisper', while they are Scheme/Lisp centric, you should be able to translate the syntax into Ruby for the most part, or grab a free Scheme/Lisp interpreter and go from there. --=20 Eric Hodel - drbrain@segment7.net - http://segment7.net All messages signed with fingerprint: FEC2 57F1 D465 EB15 5D6E 7C11 332A 551C 796C 9F04 --DheUW4aQn8WJk6WR Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (FreeBSD) iD8DBQE994y0MypVHHlsnwQRAgq0AKDJ6sM6U3dGNusPH4cNUAsKsG0nSwCgoKfy J9FIe6D8AkRc341g1b9Xvp4= =IyI+ -----END PGP SIGNATURE----- --DheUW4aQn8WJk6WR--