Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Nailing methods, procs and blocks once and for all

Reply
Thread Tools

Nailing methods, procs and blocks once and for all

 
 
Eli Bendersky
Guest
Posts: n/a
 
      04-16-2006
Hi All,

Is there a tutorial somewhere that clear away all questions that newbie
Rubyists have about methods, procs and blocks ? Most importantly:

- When is each typically used
- How are they converted to-and-from one another
- How they are used to express common functional programming idioms:
functions as first-class constructs, anonymous functions, passing
functions around, closures, and so on.

I think a single resource explaining this topic would clear much of the
questions that arise on comp.lang.ruby almost every week.

Kind regards,
Eli

 
Reply With Quote
 
 
 
 
Robert Klemme
Guest
Posts: n/a
 
      04-16-2006
Eli Bendersky wrote:
> Hi All,
>
> Is there a tutorial somewhere that clear away all questions that newbie
> Rubyists have about methods, procs and blocks ? Most importantly:
>
> - When is each typically used
> - How are they converted to-and-from one another
> - How they are used to express common functional programming idioms:
> functions as first-class constructs, anonymous functions, passing
> functions around, closures, and so on.
>
> I think a single resource explaining this topic would clear much of the
> questions that arise on comp.lang.ruby almost every week.


Does this help?

http://www.rubygarden.org/ruby?ClosuresAndBlocks

There might be more on that Wiki.

Happy Easter

robert
 
Reply With Quote
 
 
 
 
Eli Bendersky
Guest
Posts: n/a
 
      04-16-2006

Robert Klemme wrote:
> Eli Bendersky wrote:
> > Hi All,
> >
> > Is there a tutorial somewhere that clear away all questions that newbie
> > Rubyists have about methods, procs and blocks ? Most importantly:
> >
> > - When is each typically used
> > - How are they converted to-and-from one another
> > - How they are used to express common functional programming idioms:
> > functions as first-class constructs, anonymous functions, passing
> > functions around, closures, and so on.
> >
> > I think a single resource explaining this topic would clear much of the
> > questions that arise on comp.lang.ruby almost every week.

>
> Does this help?
>
> http://www.rubygarden.org/ruby?ClosuresAndBlocks
>


Thanks, I will look into this.
In any case, driven by sheer curiosity I set out to write an article on
this topic. I will post a link once it's finished.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Article: understanding Ruby blocks, Procs and methods Eli Bendersky Ruby 0 04-18-2006 06:36 AM
Object#send and blocks/procs Mehr, Assaph (Assaph) Ruby 2 09-27-2004 05:58 AM
procs/blocks - blocks with procs, blocks with blocks? matt Ruby 1 08-06-2004 01:33 AM
Can't make two request at once, one blocks all..... Ford Prefect alias Armin ASP .Net 2 12-03-2003 09:29 PM



Advertisments