cout << "The calculator 0.1.0" << endl;
cout << "--------------------" << endl;
cout << "How to use:" <<endl;
cout << "1. Type the first number and press the Enter key." << endl;
cout << "2. Type the operation char and press the Enter key." << endl;
cout << "3. Type the second number and press the Enter key to watch the result." << endl;
cout << "4. To quit type the zero and press Enter key." << endl;
Zamiast endl można skorzystać z \n
do
{
cout << "Enter the second number: ";
cin >> b;
isWrong = cin.fail();
cin.clear();
cin.ignore( 1000, '\n' );
}
while (isWrong != 0);
while dałbym w tej samej linijce, w której jest }
Poza tym z funkcjonalności: dodałbym możliwość dzielenia z resztą