Identifying Remainders in Developer Help
|
|
I trying to implement odd formulas (this one requiring the use of only remainders :) ) I need to check if the remainder of n divided by 4, equals 2 or 3.
How would I do this?
I'm starting to think this:
if(text2num(copytext("[Attacker.HPIV/4]",lentext("[Attacker.HPIV/4]")-1,lentext("[Attacker.HPIV/4]")))==2) ...
|
But it looks a little long...
|
if(n % 4 == 2 || n % 4 == 3)
...