Nathan Powell wrote:
> Why don't you show us what you have, and where you are stuck, rather
> than us translating it for you in it's entirety.
> 
sorry about that.
things I would like to know are:

1) How would we write following method?
   the one which takes an array and return subref (whatever equivalent 
in Ruby)
   something like this(in perl)
sub get_random_val_generator {
    my $arr = shift;
    return sub { return $arr->[ rand @$arr] };
}

2) How to store these references(subrefs) in a hash or some variable?
3) How would you do(approach) this in Ruby(the script)?

Since I know very little about Ruby so I don't the construct used for 
this purpose?
-- 
Posted via http://www.ruby-forum.com/.