lambda/proc/metaprogramming with Ruby

A

Aldric Giacomoni

Hi all,
I'm looking for good tutorials which explain how to use the two tools of lambda
and proc (which, ideally, would also help me learn how to think in such a fashion).
I think that would solve the third issue as well: metaprogramming, aka writing
code that writes code.. But if not, do you know of a good tutorial for that as
well? :)

Thanks,
 
P

Pascal J. Bourguignon

Aldric Giacomoni said:
I'm looking for good tutorials which explain how to use the two tools of lambda
and proc (which, ideally, would also help me learn how to think in such a fashion).
I think that would solve the third issue as well: metaprogramming, aka writing
code that writes code.. But if not, do you know of a good tutorial for that as
well? :)

The best would be to read SICP (and watch the lectures).
Notice the wiki with the exercises translated in other programming languages.

SICP = Structure and Interpretation of Computer Programs
http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-4.html
http://swiss.csail.mit.edu/classes/6.001/abelson-sussman-lectures/
http://www.codepoetics.com/wiki/index.php?title=Topics:SICP_in_other_languages
http://eli.thegreenplace.net/category/programming/lisp/sicp/
 
R

rmagick

Hi all,
I'm looking for good tutorials which explain how to use the two tools of lambda
and proc (which, ideally, would also help me learn how to think in such afashion).
I think that would solve the third issue as well: metaprogramming, aka writing
code that writes code.. But if not, do you know of a good tutorial for that as
well? :)

Regarding metaprogramming, I highly recommend Dave Thomas' "The Ruby
Object Model and Metaprogramming" series of screencasts. Very clear
explanations, nicely narrated. Dave uses TextMate to demonstrate code
snippets.

http://pragprog.com/screencasts/v-dtrubyom/the-ruby-object-model-and-metaprogramming.
 
J

James Gray

Regarding metaprogramming, I highly recommend Dave Thomas' "The Ruby
Object Model and Metaprogramming" series of screencasts. Very clear
explanations, nicely narrated. Dave uses TextMate to demonstrate code
snippets.

http://pragprog.com/screencasts/v-dtrubyom/the-ruby-object-model-and-metaprogramming
.

I agree. That series is simply excellent.

I also wrote a little bit about blocks and lambda on my blog a while
back:

http://blog.grayproductions.net/articles/code_as_a_data_type

James Edward Gray II
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,797
Messages
2,569,646
Members
45,373
Latest member
Vast3

Latest Threads

Top