static int compareMonth(DstTime x, int mon) { if (x.mon < mon) return -1; if (x.mon > mon) return +1; return 0; }