Hi,

>
>   for(int n=0;n<10;n++)
>    {
>      sleep(2);
>      cout << (n/9.0) << "%\n";
>    }
>

#include <iostream>
using namespace std;
int main()
{
       int i = 0;
       cout<<"\nHello World\n"<<endl;
       for (i=0;i<10;i++)
       {
               cout<<"i is now: "<<i;
               fflush(0);
               sleep(2);
               cout<<"\r";
       }
       cout<<endl;
}

that should display "i is now: X" is same line every time. Apologies
for the C C++ mix.


Regards,

Soyuz
-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to