Store your results in a hash. Use the names as hash keys and the values as hash values. Prompt the use to enter one of the hash keys. Look up the value un the hash. If the key is not in the hash, ask the user to try again.
Bill
Comment on Re: Using user input to return variable typed.