For example why 2 %-8
results in -6?
I was reading What is the result of % in Python? nut I didn't manage to get it, for example I read in comments exaplanation of
7%2
its 7-2=5
and then 5-2
= 3
and then 3-2
= 1
and so thats the result, but can't manage to apply that to
2 - (-8) = 10 - (-8) = 18
, can someone explain? and whats the criteria to stop? thanks :)