I think that's going to lead to the question of what is a month? 365.25/12 days? What's a month before March 30? Two months before March 30? Does (March 30 - 2 months) == (March 30 - 1 month - 1 month)? Now that I'm confused (how about you?) GregorianCalendar class has an add method that lets you specify +-n of some unit. See if it will take month as the unit. Then try those cases above and see if you like the results!
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
Oops, I failed to read the question, didn't I? My rant was off topic - about how to add or subtract months to dates. There are "officially correct" answers to all those questions I threw out. But this is tricky enough to use somebody else's solution rather than write one. Still, ask yourself what the results of the calculations above mean ... what is "exactly two months"? Same day-of-month two months ago? Or 59 or60 days ago (Jan + Feb)?