I have a text file with a list of 4 digit codes inside of it as such:
4317
2352
2315
At a point in my code I ask users to input there 4 digit code, what I want to do is to then match it so if they say their code is 4317 it gives me 0 and then I want to use that number to find something in a second list that is full of names as such:
John
Jen
James
Joe
So if I type in 4317 it gives me 0 and then I want to print what number 0 thing is in the second list. I am completely stumped on how to do this, both lists are in separate .txt files.