Functional Programming in Perl: Part 2

By | May 7, 2011

* Closures

Lets take a look on closures:-

Need of closures:

Since closures are subroutine references with a bit of private data thrown in, they are very convenient to use as callback procedures in graphical user interfaces. There is a nice example which explains the need of using closures. This commonly used approach is called “smart” callback procedure.

For more info you can read chap 4 of Advanced Perl Programming by Sriram Srinivasan.

One thought on “Functional Programming in Perl: Part 2

  1. Pingback: Functional Programming in Perl: Part 2 « Pradeep's world of … | Guide 2 Serv Online

Leave a Reply

Your email address will not be published. Required fields are marked *