Answered step by step
Verified Expert Solution
Question
1 Approved Answer
C++, please! Kevin wrote a program to solve the problem seen below, but there are a few bugs so it's not passing the code runner
C++, please!
Kevin wrote a program to solve the problem seen below, but there are a few bugs so it's not passing the code runner tests. Your task is to fix any bugs in the program so that it will pass the test cases. You cannot replace the if-else block with a switch statement. Problem: Kevin needs to take a vacation. To help make his trip plan, please write a program that takes a month as an integer, then print which season it is. Use the table below to find which month belongs to which season in Canada). Season Month spring 4-5 summer 6 - 9 autumn 10 - 11 winter 12-3 If the entered value is not between 1-12, then print "invalid" Here is Kevin's code: using namespace std; int main() { char month; cout > month >> endl; if (month >= 1 && month = 4 && month = 7 && month = 10 && month = 1 or month
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started