Developing on my previous question I'm wondering whether there is a way to have an element in a list and find that position in another list and return what is in the position as a variable. for example:
list1 = [0,1,2,3,4]
list2 = ["0","hello","my","name","is","Daniel"]
if the user enters the number 14 the program will return "hello Daniel" in the sense that the computer reads 14 as 1 and 4 and finds the position in list as an example.
I've tired using [list2.index(x) for x in list1]
hoping that it would work but I've been unable to change the code so it does work. is there a simple way to do it