+ 1
x, y = y, x+y meaning?
Could you explain the steps occuring? Def f(n): x = y = 1.0 for i in range (1,n): x,y = y, x+y return y/x Print (f(3))
3 Respuestas
+ 1
x, y = y, x+y
x is assigned y
y is assigned x+y
+ 1
Sorry, mistype. Should be y/x
Could you explain the steps occuring? Def f(n): x = y = 1.0 for i in range (1,n): x,y = y, x+y return y/x Print (f(3))