my %maps; foreach my $game (qw( cstrike ... )) { $maps{$game} = [ MAP::get_game_maps($game) ]; }