The etymology of Proc and proc is procedure. The word Procedure is
pretty generic in terms. It can mean method, function, routine, and
subroutine. It's definition is a set of instructions independent from
main. From a procedural programming point of view everything called
from main is a procedure.

In ruby main is an object so therefor everything called inside main is
a method call.

Ruby doesn't really have functions inherently since the last statement
of instructions always implicitly returns a value even if it's thrown
away on the level of the caller. To make it more interesting Proc.new
returns an object of the function so it could potentially be called a
function object (i.e.functor).

But these are really semantics. Knowing how Proc.new and lambda differ
are more important than where the name of the constructor came from as
it could have easily been named Block.new

Brian Cander's link to closures-in-ruby.rb is a really well documented
read on the idiosyncrasies and form of functional programming inside
ruby.

~

On Fri, Apr 29, 2011 at 4:27 AM, Ronnie Aa <liquid98 / gmail.com> wrote:
> Brian Candler wrote in post #995710:
>> Ronnie Aa wrote in post #995637:
>>> Could this problem be solved with a procedure also???
>>
>> There are no procedures in Ruby - only methods.
>>
>
>
> With procedures I mean this:
>
> http://www.ruby-doc.org/core/classes/Proc.html.
>
> 'Proc' is a abbreviation of procedure isn't it?
>
>
>
> Thnx for your help and the information,
>
>
>
> Ronnie
>
> --
> Posted via http://www.ruby-forum.com/.
>
>