I’ve a problem and I have no idea how to solve it.
Well, I’ve written a small Python program. It calculates a number and then should output another number. E.g. when the solution is below 100 it should print ‘100m’, when it’s <200 it should print ‘101m’, <300 = ‘102m’ etc…
I could write something like
if solution < 100:
print '100m'
elif solution < 200:
print '101m'
elif solution < 300:
print '102m'
Would be possible BUT I think it’s impossible to do that again and again until 1000 or 2000 and it would look weird in the code. 😉
Hope there is an answer… (Oh and sorry for my bad English and Python knowledge)
(You really just want to divide by 100 and round down.)