+ 2

python while loop invalid syntax

its a problem of codewars iam trying to solve the thing is i dont understand why while loop giving an error invalid syntax thanks def moving_average(values,n): lst=[] z=0 if n<=0: return None elif n>len(a): return None else: While True: lst.append(sum(values[z:n])/2) z=z+1 n=n+1 if n>=len(a): break return lst

4th Nov 2020, 11:26 AM
Abdul Majeed Faraz
Abdul Majeed Faraz - avatar
1 Respuesta
+ 2
hahahahaha i cant stop laughing thanks
4th Nov 2020, 11:52 AM
Abdul Majeed Faraz
Abdul Majeed Faraz - avatar