Never seen anything like this. Simple while loop:
t_end = 100.0
t_step= 0.1
time = 0
while time<=t_end:
time+=t_step
print time
Last 3 printed values:
...
99.9
100.0
100.1
Looks right to me.
Now, I change t_step to 0.01:
t_end = 100.0
t_step= 0.01
time = 0
while time<=t_end:
time+=t_step
print time
Last 3 printed values:
...
99.98
99.99
100.0
Question: Why it doesn't go for the final loop when time = t_end =100.0 ?
What is the alternative solution?