How can I verify a value entered in text file to defined list?