same thing.... ur just connecting to someone elses system clock.
same thing.... ur just connecting to someone elses system clock.
Free the weed!! Class B to class C is not good enough!!
And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi
pode, you have no idea how much your stupid flames make me not want to help you, but sorensen, tgm, and stoned coder are right. The only way I can think to count 1 second without using the system clock is to use a tight loop that executes some set number of times that just happens to come out at 1 second. Test with a stopwatch. This is ridiculous.
-Govtcheez
[email protected]
why would you do it any other way, when this works?Code:#include<time.h> #include<iostream.h> #include<windows.h> const int x = 2; int main() { do { time_t hold_time; hold_time = time(NULL); cout << "This code is messy, but it works" << endl; cout<<"The date is: "<< ctime(&hold_time) << endl; Sleep(1000); system("CLS"); } while(x < 1000); return 0; }
why would you do it any other way, when this works?Code:#include<time.h> #include<iostream.h> #include<windows.h> const int x = 2; int main() { do { time_t hold_time; hold_time = time(NULL); cout << "This code is messy, but it works" << endl; cout<<"The date is: "<< ctime(&hold_time) << endl; Sleep(1000); system("CLS"); } while(x < 1000); return 0; }
This is a clock which is handled by system and graphics mode but not in oop.
All is well that ends well
Before you come in here and make petty attempts, why dont you actually learn about this stuff, take a class or something, i am learning all this easily in a class. So deal with what we provide you and try to understand it yourself.