Very new at this. I tried to figure out what the problem was here but there is an error specifically telling me that there is no "if" before the "else" and I am not sure why that is.
if ((month == 1) && ((day >= 20) && (day <= 31)))
cout << "you are all good.\n";
cout << "good day\n"; // This is not part of the previous if statement
{ // These curly braces have essentially no effect here
if ((day == 20) || (day == 21))
cout << "blah\n";
cout << "blahblah\n"; // This is not part of the if statement above
}
else // No matching 'if' for this 'else'
cout << "Bad day.\n";
(This is the same code you posted; I just reformatted it to show the errors.)
Thank you both, and thank you Stephanie for the more clear response. I figured it out finally and did something very similar to what was posted above and it worked. I will use your post if I run into another error.