This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
This is simple math. When the result of the subtraction is not as expected, what are the unexpected values going into the subtraction operation?
Instead of saying, "I'm getting the wrong result", find out why. What wrong values are being fed into the expression? It's pretty clear that you haven't found a bug in the subtraction operator, os the problem must be in the operands. What are they? How are they different from what you expect? [ August 01, 2007: Message edited by: Bear Bibeault ]
Joined: Jan 12, 2004
are you talking about putting in getYear instead of getFullYear?