Hi, this is a mathematical question, but I'm doing it in VB so I thought I'd post it here...
A person is shown a total of 10 numbers. When a number appears on the screen they have to type that number into a text box and if they get it correct another number appears. If they do not get it correct they get another chance at getting the original number correct.
I'm trying to work out the accuracy of the values they input (and then I display that accuracy as a percentage when the program has finished.) For example, if they input 11 values (i.e. 1 of them is not the correct number) then I'm guessing the accuracy is approximately 90%. But what is the formula to obtain this figure/percentage?
Do you let them try a second time with the original number and when they get it right the second time you still take off for that? Before you have a formula you have to have the exact rules. Anyway, let me try to answer your question even without knowing the exact rules, you can adapt it accordingly let's say you give them 10 questions you have a variable called mistake. Every time they got an answer wrong you add 1 to mistake. 10 = 100% so for each mistake you take off 10%. So your formula would be 100-(mistake*10)
Okay, to cut a long story short, I finally got it. For some reason I had to declare "success" in the general declarations section. I don't know how, but it fixed the problem and now I'm using the exact code you provided zmariow. Thanks for that!