#include using namespace std; bool isLeap(int); int dayNumber(int month,int day,
ID: 3653220 • Letter: #
Question
#include using namespace std; bool isLeap(int); int dayNumber(int month,int day,int year) { int count; if(isLeap(year) && month==2 && day==29) return 60; if(month==1) return day; else if(month==2) return 31+day; if(isLeap(year)) count=60; else count=59; for(int i=3;i<<"Enter Month: "; cin >>month; cout<<"Enter Day: "; cin>>day; cout<<"Enter Year: "; cin>>year; cout<<" "; if(month==1) cout<<"Januray"; else if(month==2) cout<<"February"; else if(month==3) cout<<"March"; else if(month==4) cout<<"April"; else if(month==5) cout<<"May"; else if(month==6) cout<<"June"; else if(month==7) cout<<"July"; else if(month==8) cout<<"August"; else if(month==9) cout<<"September"; else if(month==10) cout<<"October"; else if(month==11) cout<<"November"; else if(month==12) cout<<"December"; cout<<" "; cout<<day<<","<<year<<" is day "; cout<<dayNumber(month,day,year); if(isLeap(year)) cout<<" (leap year)"; } why when i put the last enter exit automatically oft he debug! please help me with this program!Explanation / Answer
add either of these line depending on your compiler: cin.get();cin.get(); system("pause");
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.