I'm trying to create a program that would display the reaction time of a person
reaction to an object on the computer. I don't know how to write this code.
Suggestions would be great.
Re: Reaction Times
First of all, you want to post technical questions on the c++.general
ng. Anyway, depending on the stimulus you intend to present, say a
character, a number or a string, you can do something like the
cout<<"press a key immediately after the stimulus has been shown"<<endl;
cout << stimulus <<endl;
// here you start counting time
time_t end = time();
If it's likely that the reaction time is shorter than a second, you want
to use the clock() function or the follwoing class:
> I'm trying to create a program that would display the reaction time of a person
> reaction to an object on the computer. I don't know how to write this code.
> Suggestions would be great.
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL