john massey
Advanced Newbie
Joined: 26 Jul 2009 Posts: 50
|
Posted: 28 Dec 2009 10:21:52 pm Post subject: |
|
|
Here is all the code in all it's glory. It skips. However when I input the answer for particular and answer with the correct answer The program responds telling me that I put in the wrong answer. Then the programs displays the same problem in the same location. This time I put in the same answer and the program tells me that was the correct answer.
So here is all the code with some comments. Fire away with questions.
":YOU ROCK:YOU ARE AWESOME:WAY TO GO!:YOU ARE GOOD:"→Str1 // these are the congratulation messages
ClrDraw:CoordOff:GridOff:AxesOff:ZStandard:Full:FnOff:ClrHome:While 0:setup graph screen:End
Output(1,1,"REDUE 2 1
1:prgmCENTEXT // this is a program that randomly select on of these massages each time there is no error
prgmINITPLA1
6→L
prgmPUTO //puts in the "0" in OVER1
Output(1,1,⌊OVER1 // checks to see if it is ok
Pause
ClrHome
For(J,1,dim(⌊OVER1// i do not think this is necessary because OVER1 always has 16 elements
If ⌊OVER1(J)=0 // as requested
End
prgmCLEAR6 // all the clears are just enough spaces to clear a row. In this case row 6 on the graph screen
prgmLA10SMAL // This a small line program that makes all the frames around the flash cards/ problems. There are 10 flash cards on each graph screen
W+1→W
//from here on down until further notice the program lays out all the 16 flashcards. This is where the skipping should take place
{6,32,8,9,10,3,12,16,6,4,42,7,8,6,7,11}→⌊FN002:While 0:FIRST NUMBER IN MATH PROBLEM:End
{20,20,20,20,20,42,42,42,42,42,20,20,20,20,20,42}→⌊FY002:While 0:Y VALUE FOR STARTING POINT OF PROBLEM & LOCATION OF FIRST NUMBER:End
{4,24,43,62,81,4,24,43,62,81,4,24,43,62,81,4}→⌊FX002:While 0:X VALUE FOR STARTING POINT OF PROBLEM & LOCATION OF FIRST NUMBER:End
Text(⌊FY002(J),⌊FX002(J),⌊FN002(J)
{6,32,8,18,20,6,24,1,1,8,42,14,16,12,8,12}→⌊SN002:While 0:SECOND NUMBER IN MATH:End
{26,26,26,34,34,57,57,50,50,57,26,34,34,34,34,57}→⌊SY002:While 0:VERTICAL VALUES FOR SECOND NUMBERS:End
Text(⌊SY002(J),⌊FX002(J),⌊SN002(J):While 0:PRINT SECOND NUMBER:End
{1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1}→⌊SS002:While 0:THIS SETS THE OPERATOR SINE '1' FOR + , '2' FOR - AND '3' FOR X :End
If ⌊SS002(J)=1 // this says that all the sines are + for all the programs in REDUE21
Text(⌊FY002(J)+6,⌊FX002(J)-4,"+":While 0:PRINT +:End
If ⌊SS002(J)=2
Text(⌊FY002(J)+6,⌊FX002(J)-4,"–":While 0:PRINT –:End
If ⌊SS002(J)=3
Text(⌊FY002(J)+6,⌊FX002(J)-4,"x":While 0:PRINT X:End
// below are the little lines in each flash card that fall below the the two numbers in each flash card
{1,21,40,59,78,1,21,40,59,78,1,21,40,59,78,1}→⌊X1002:While 0:THESE ARE THE START VALUES FOR LINE VARIABLES:End
{–33,–33,–33,–33,–33,–56,–56,–56,–56,–56,–33,–33,–33,–33,–33,–56}→⌊Y1002:While 0:VERTICAL VALUES:End
{17,36,55,74,94,17,36,55,74,94,17,36,55,74,94,17}→⌊X2002:While 0:THESE ARE THE STOP VALUES FOR LINE STATEMENTS:End
Line(⌊X1002(J),⌊Y1002(J),⌊X2002(J),⌊Y1002(J)
{12,64,16,9,10,3,12,17,7,4,84,7,8,6,1,1}→⌊AN002:While 0:THE ANSWERS ARE STORED HERE:End
{34,34,34,26,26,49,49,57,57,49,34,26,26,26,26,49}→⌊UD002 //this is the vertical values of the ? mark
Text(⌊UD002(J),⌊FX002(J),"?" // this is the prompt for the child. they should 1) recognize the prompt as a call to action 2) decide on an answer 3) input the correct number from the keyboard and press good 105 in less that 3 seconds so that JONL5 will hold that J number
prgmSTARTIME // here is where the processing of the data begins. Note the ? mark above. This starts the timer
prgmGETNUM1 // this program returns the input from the child and stops the timer
prgmSTEP31 // a list called JONL4 holds all reaction times. If JONL4>3 that is an error condition and JONL5 will hold that value
prgmDISTIME1 // this displays the particular reaction time and the total of all reaction times thus far.
If expr(Str9)=⌊AN002(J) //expr(Str9) is the number returned by the child in GETNUM1 ANOO2(J) is the correct answer
Then
2:prgmCENTEXT // this displays a congratulation message with a correct answer.
Text(⌊UD002(J),⌊FX002(J),⌊AN002(J) // this writes over the ? mark.
Else
// all this stuff below I call the error bucket as opposed to the long times in JONL5
Text(⌊UD002(J),⌊FX002(J),⌊AN002(J) // this line puts in the correct answer
E+1→E // This a carry over which I do not use any longer
prgmCLEAR6
Text(6,0,⌊AN002(J)," NOT ",expr(Str9) // this line tells the child of their mistake
J→⌊JONL1(1+dim(⌊JONL1 // JONL1 holds all the J values where an error occurred
End // this is the end of this the For, next ,else loop
Pause // this pause gives the child a chance to see what has happened in the execution of a particular flash card. They can see reaction time on line 12 of the graph screen and congratulatory messages or error messages on line 6 of the graph screen.
3:prgmCENTEXT //this clears line sis
4:prgmCENTEXT // steps to the next message to be called in the next loop
ClrDraw
End
prgmSUMRED21 // this routine is supposed to Combine JONL1 and JONL5 to make a new value of OVER1 and recall REDUE21. Since the original code has a "0" in space 2 there should be no such value here, but there is. I assume that when we solve the repeating issue this will correct itself.
End// then end :biggrin: |
|
john massey
Advanced Newbie
Joined: 26 Jul 2009 Posts: 50
|
Posted: 29 Dec 2009 11:31:40 am Post subject: |
|
|
I have found a bug in REDUE21. I do not know why or how to fix it.
I my initialization Program I did this:
ClrList ⌊JONL5
SetUpEditor ⌊JONL5
The bug centers around this block of code.
For(J,1,dim(⌊JONL4
If 3<⌊JONL4(J
J→⌊JONL5(1+dim(⌊JONL5
End
What it supposed to do is to index JONL5 whenever JONL4 is > three seconds.
Well L4 holds {3,4,4,3,2,3,3, 2,3,3,3,4}
If everything were working correctly JONL5 would hold {2 3 12} because these are the only values where JONL4 is > three seconds.
JONL5 holds{2,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,12}
You can see JONL5 got the first and last numbers correct. I have no idea where this other stuff comes from. |
|