• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 702
  • Last Modified:

Programming language for reaction-time program -- need advice

I need to write a program that will be used for a psychology experiment.  The program will display a series of very simple math problems, such as these two:

9 - 7 =
2 x 4 =

The answer is always a single digit.  The program will keep track of the amount of time it takes the user to hit the correct key.  The number of problems will be specified at the beginning of the run.  At the end of the run, the program will create a text file that contains the problems answered, whether the correct answer was given, and the reaction time.

It's very important that the program give accurate results.

I'm not a programmer, but I took some programming courses in college (mostly in PL/I but also in Pascal and APL).  I'm looking for recommendations for a programming language that is free, reasonably easy to learn, and runs under Windows 7.

I don't much care about things like the ability to create a fancy user interface.  The program will not be sold.

Thanks in advance.
0
chernavsky
Asked:
chernavsky
  • 4
  • 4
  • 2
  • +3
5 Solutions
 
aviranCommented:
definitely java or C#

if you choose java, use eclipse for development/
if you choose c#, you can use visual studio express which is also free
0
 
ThommyCommented:
You can use FreePascal, which is available for multiple platforms.
Windows-version supports Win 7...

Download Page
http://www.freepascal.org/download.var
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
...or the other free IDE from Microsoft, Visual Basic.Net Express:
http://www.microsoft.com/visualstudio/en-us/products/2010-editions/visual-basic-express

You can make a Console or Form based app with it.
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
5g6tdcv4Commented:
0
 
utapyngoCommented:
New to programming? Python is free, and easy to learn:
http://wiki.python.org/moin/BeginnersGuide

And it runs perfectly under Windows 7.
It has a built-in interactive shell which you can use as a calculator:
>>> 9 - 7
2
>>> 2 * 4
8

Open in new window

I also recommend installing IPython. It is a very good extension to the built-in Python shell.
0
 
chernavskyAuthor Commented:
Thanks for all the tips.  Does anyone have an idea about how to verify that the reaction-time measurements are accurate?  I wouldn't even know how to approach this.
0
 
5g6tdcv4Commented:
Here is some very simple code that starts a timer before each question and ends the timer after each question. It is measuring in Milliseconds

the test.txt is the compiled exe for the code I attached, just rename to test.exe
MsgBox(0,"Test","Your Test will start when you click Ok")
$begin = TimerInit()
$1value = InputBox("Question", "9 - 7 =  ?", "", " M2")
$1dif = TimerDiff($begin)
$begin = TimerInit()
$2value = InputBox("Question", "9 + 7 =  ?", "", " M2")
$2dif = TimerDiff($begin)








MsgBox(0,"Time in MS to answer question 1",$1dif)
MsgBox(0,"Time in MS to answer question 2",$2dif)

Open in new window

test.txt
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
"...and runs under Windows 7"

As a multi-tasking operating system, anything you do will not be accurate at the millisecond level!
0
 
chernavskyAuthor Commented:
@Idle Mind: So how do I get around that problem?  I really need the data to be accurate.  The typical reaction time is somewhere on the order of 200 milliseconds.
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
...don't use Windows for a system that needs accuracy down to the millisecond level?  =\

Normal operating system ~actions~ can add 50+ milliseconds to the time.

One way to reduce the problem is to give the test multiple times and then average the results.

Also, make sure that you don't have things like virus scanners, backup systems, scheduled updates, etc set to run when the system is supposed to be used.  Turn off desktop background switching, etc...
0
 
chernavskyAuthor Commented:
@Idle Mind: What about doing it in Ubuntu, or some other flavor of Linux?  Would that give better results?
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
I don't have any experience with them sorry...but I'm guessing you probably have more control over what is loaded at any given time.
0
 
chernavskyAuthor Commented:
Thanks for all the helpful information.  Will have to spend some time investigating options.
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

  • 4
  • 4
  • 2
  • +3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now