Hello daniweb!
i have recently started to learn c++ and have made a few programs, (a hello world and a multiplication program) following some tutorials. So i decided to try and make my own, but it did not go well. After debugging in microsoft visual c++ 2010 i got loads of errors, and i am not sure what i have done wrong.
//Revision times generator
#include <iostream>
#include <string>
using namespace std;
int main () {
string day;
cout << "What day is it today?";
getline(cin, day);
if (day == 'monday') {
cout << "you should revise computing today." << endl;
} else if (day == 'tuesday') {
cout << "you should revise math today." << endl;
} else if (day == 'wednesday') {
cout << "you should revise biology today." << endl;
} else if (day == 'thursday') {
cout << "you sould revise modern studies today." << endl;
} else if (day == 'friday') {
cout << "you should revise french today." << endl;
} else if (day == 'saturday') {
cout << "you should revise chemistry today." << endl;
} else if (day == 'sunday') {
cout << "take a break today." << endl;
} else
cout << "no valid day entered." << endl;
system ("pause");
return 0;
}
any help would be great.