Try some input like:
previousSickMonth = 1
employmentMonth = 5
tempMonth = 2
With
Code:
--------------------
tempMonth = 12 - previousSickMonth - employmentMonth + tempMonth
--------------------
I got 8.
With
Code:
--------------------
tempMonth = 12 - (previousSickMonth - employmentMonth + tempMonth)
--------------------
I got 14.
But I know what the problem is, if you work out the bracklets first,
you could get an negative number. Obviously a subtract a negative
number and you get a positive number, hence the difference.
But to be honest, this is the first time I've ever experienced a
difference in two expressions that consisted of only addition and
subtraction operators.
I've always been under the impression that bracklets don't mean
anything with only addition and subtraction operators. I guess I was
wrong.
--
FCC
------------------------------------------------------------------------
FCC's Profile:
http://www.excelforum.com/member.php...o&userid=35888
View this thread:
http://www.excelforum.com/showthread...hreadid=557981