That actually is not the body for that particular function because the parameter list is different. So the compiler treats them as two separate functions.
Note the difference:
1 2 3
void printCalendarHead(int&); // your prototype
void printCalendarHead(/*in*/ int currentMonth) // your function body
The prototype is taking a reference (int&) and your function body is taking a normal int.
Change one of them so they match. I'd lose the reference.
worked a charm. programs not working though. could u take a look at this and tell me where its going wrong? the february month is still showing 31 days instead of 28.
haha that worked. placement error. it was automatically setting daysInMonth = 31. But now i'm having the same problem with the february if's.... looks like i did the same thing there too. Thanks again!