in reply to Interpolation of variables read from a file

You can do it that way, but I suggest that you separate actual variable assignments from your data file, and instead just have a complex data structure.
# data.pl ( act => { "food" => "eat it", "drink" => "drink it", "Perl" => "play it", }, act1 => { "foo" => "bar", "baz" => "biz", }, );
Then in your code, you can iterate on keys instead of this hardcoded list.
my %hash = do 'data.pl'; my $item = "Perl"; my $out = grep {-p $_->{$item}} values %hash ? 1 : 0;
Or something to that effect.

- Miller