|
From: Louis B. <bar...@ho...> - 2001-03-07 19:16:11
|
I'm another one of those guys leaving harvesting and trying out programming.
In this program I must display the time, secs, mins, and hours. I'm still
working on it, I was wondering if there is a better way to make it wait a
minute than doing a while loop. Also, I don't want the thing scrolling down
the screen, it seems like it should not move, I have'nt wrote that part, but
I will tonight. I would think that you don't do carriage return line feed,
and use a backspace character ?
Here's my member function prototype in the class Time
// Wait a second
void wait_a_second();
Here's my "While Loop" definition in the Function File
// Wait one second, set for Intel Celeron Processor 366MHZ
void Time::wait_a_second()
{
int count_down = 51000000; //iterations for 366 celeron pocessor
//Wait for second to lapse
while(count_down > 0) //simple repetitive instruction
{
count_down += -1; //decrement value in variable
}
}
Again, I will be working on the stationary display tonight.
thanks for any ideas
Louis
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com
|