3

make c++ wait

view full story
linux-howto

http://www.daniweb.com – I am after making my program wait before responding to the users input, what code do i use for this and how do i implement it? #include <iostream> using namespace std; int main() { char instuctions = 0; int A =  0;  // user input 1  int B = 0;  // user input 2 float total = 0; // total of input 1 and input 2 with addition float total2 = 0; // total of input 1 and input 2 with subtraction float total3 = 0;  // total of input 1 and input 2 with division float total4 = 0;  //  total of input 1 and input 2 with mulitiplaction int total5 = 0; int restart = 0;  // continue or exit application         cout << "Welcome to the Calculator, " << endl;         cout << endl; loop: // loops the program if user continues cout << "Enter first Number "; cin >> A; // lets the user input first value cout << endl;         cout << "Enter second number "; cin >> B; // lets the user input second value cout << endl;         total = A + B; // works out addition of A and B cout << A << " + " << B << " = " << total << endl;         total2 = A - B; // works out subtraction of A and B cout << A << " - " << B << " = " << total2 << endl;         total3 = A / B; // works out division of A and B cout << A << " divided by " << B << " = " << total3 << endl;         total4 = A * B; // works out mulitplaction of A and B cout << A << " * " << B << " = " << total4 << endl; cout << endl; cout << "Press 1 to continue using this calculator or 2 to exit "; cin >> restart;                 if (restart == 1)                         {                         goto loop;                         }                         else                         {                         return 0;                         }                         }im after the aplication to say eg. 1 + 1 = 2 wait couple of millieseconds then say 1 * 1 = 1 etc..etc (General)