in reply to pulling value based on input

Hi,
please use <code> tags for your code examples and <c></c> for your inline code. Also using perltidy to tidy up your longer code is very much recommended. This makes your posts much more readable.

To access the read server and location use $servers{$server} and $locs{$loc} as shown below. You can - and should - also check if the given server and location really exists, which can be done with if (exists $servers{$server}) { } etc.

my %locs = ( one => '\c$\files', two => '\d$\stuff', three => '\d$\things' ); my %servers = ( ksl => '\\server1', krf => '\\server2' ); my $server = <STDIN>; chomp $server; my $loc = <STDIN>; chomp $loc; print $servers{$server}, "\n"; print $locs{$loc}, "\n";