That is a good solution i agreehippy wrote: ↑Sat Jun 01, 2019 7:28 pmIf not going for what I consider my more elegant 'frange()' solution above, I would recommend -Code: Select all
print("start") t = 0.0 while t <= 1000.0: # some other stuff here t += 0.001 print ("complete")
This is simple and sufficient for your requirement in pythonghp wrote: ↑Tue May 28, 2019 7:04 pmCode: Select all
print("start") t = 0.0 while True: t += 0.001 if t > 1000: break # some other stuff here print ("complete")