Page 1 of 1

easy count

Posted: Wed May 06, 2009 12:36 am
by greggarcia
Hello i am still testing RR and i do not how make an easy counting of hit, would you mind help me? i am doing just to play several question with "answer" if the kid hit the right answer i would like to count how many right answer his or her get.

Thanks
Greg Garcia

Posted: Wed May 06, 2009 5:07 am
by acidjazz
Greg,

How about this....

Code: Select all

on mouseUp
   
   answer "Which is further north? with "Spain" and "England"
   If it is "England" then  
      add 1 to counter
      answer "Right!  You now have answered" && counter && "questions correctly!" 
   else if it is "Spain" then
      answer "Sorry"   
   end if
   
   answer "Which is larger?  with "10 x 2" and "3 x 4" 
   If it is "10 x 2" then  
      add 1 to counter
      answer "Right!  You now have answered" && counter && "questions correctly!" 
   else if it is "3 x 4" then
      answer "Sorry" 
   end if
    
end mouseUp

There are many ways to do this, but an if/then statement with another answer command to give feedback is probably the easiest.

Best,
Mark P.

Posted: Wed May 06, 2009 1:35 pm
by greggarcia
Mark, Thanks so much, that's works and more important gave an idea how RR language works.

Good day.
Greg