I am a newbie in the field of programming. I am trying to learn through practice problems. But most of my codes which are showing output in IDE are not accepted here.
Can u please help why this code is not being accepted?
link: https://www.codechef.com/LRNDSA05/problems/FIBEASY
def removeodd(D):
return [D[x] for x in range(1,len(D),2)]
T=int(input())
a,b=0,1
D=list()
for i in range(T):
if i<1:
D.append(i)
else:
a,b=b,(a+b)%10
D.append(a)
while len(D)>1:
D=removeodd(D)
print(D[0])