for i in l, gives an error:
l=["Mohi", "Moki", "Lucky", "Praty", "Prem"]
k=[]
for i in l:
k.append(l[i])
print(k)
but no error when I do this:
l=["Mohi", "Moki", "Lucky", "Praty", "Prem"]
k=[]
for i in range(len(l)):
k.append(l[i])
print(k)
Blockquote