0
Can't float be used in while loop
Input x=999.0 while x>=1.0: x-=0.5 Output 999.0 999.0 999.0 ...till timed out Why is this happening
2 Respostas
+ 1
its valid (kinda)
x=999.0
while x>=1.0:
print(x)
x-=0.5
- 1
You forgot to add a space in the third line, so the while loops serves no purpose and x will always be 999