Rashmid,
Please take the time to read the code that I have posted - if you read it you will see that I do check the values for the month and day.
The code I posted was not intended to be a complete working program but as I said in my post "part of program only". I was giving an example of a basic "if/else problem" which the OP, who describes himself as a "novice to C++", had originally requested.
There is often little benefit in posting complete working programs in answer to simple basic questions.
Alan
|