Asked by Karina
How do you write a program that prints out your course schedule for a week?
Here's an example of the output for one day:
Monday 9:00 Computer Science 101
Monday 11:00 Physics 201
Monday 2:00 Dance 153
Here's an example of the output for one day:
Monday 9:00 Computer Science 101
Monday 11:00 Physics 201
Monday 2:00 Dance 153
Answers
Answered by
Karina
Just wanna know if this is right!!!
#include <iostream>
#include <string>
using namespace std;
const string DAY1 = "Monday"; //days in the week
const string DAY2 = "Tuesday";
const string DAY3 = "Wednesday";
const string DAY4 = "Thursday";
const string DAY5 = "Friday";
const string FIRST = "9:00"; //times of classes
const string SECOND = "11:00";
const string THIRD = "2:00";
const string FOURTH = "4:00";
int main()
{
cout<< DAY1 <<" "<< FIRST <<" "<<"Computer Science 101"<<endl;
cout<< DAY1 <<" "<< SECOND <<" "<<"Physics 201"<<endl;
cout<< DAY1 <<" "<< THIRD <<" "<<"Dance 153"<<endl;
return 0;
}
#include <iostream>
#include <string>
using namespace std;
const string DAY1 = "Monday"; //days in the week
const string DAY2 = "Tuesday";
const string DAY3 = "Wednesday";
const string DAY4 = "Thursday";
const string DAY5 = "Friday";
const string FIRST = "9:00"; //times of classes
const string SECOND = "11:00";
const string THIRD = "2:00";
const string FOURTH = "4:00";
int main()
{
cout<< DAY1 <<" "<< FIRST <<" "<<"Computer Science 101"<<endl;
cout<< DAY1 <<" "<< SECOND <<" "<<"Physics 201"<<endl;
cout<< DAY1 <<" "<< THIRD <<" "<<"Dance 153"<<endl;
return 0;
}
There are no AI answers yet. The ability to request AI answers is coming soon!
Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.