diff options
-rw-r--r-- | 4.N.10_Parser.php | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/4.N.10_Parser.php b/4.N.10_Parser.php index 2cc9a28..2cae2ee 100644 --- a/4.N.10_Parser.php +++ b/4.N.10_Parser.php @@ -52,7 +52,11 @@ for (i=0;i<=$numRecords;i++) for (i=0;i<=$numRecords;i++) { $tok = strtok($lines, " "); - + //this if-statement allows us to determine if a student is on his/her second attempt + if ($attempts[$question_id] == 1) + { + + } while ($tok !== false) { $student_id = $tok[0]; @@ -72,6 +76,13 @@ for (i=0;i<=$numRecords;i++) if ($submitted_sum == $correct_sum) { $num_correct[$student_id]++; + + //this if-statement allows us to determine if a student is on his/her second attempt + if ($attempts[$question_id] == 1) + { + + } + } //How many times does each student overpay - important for determining subraction understanding @@ -79,7 +90,7 @@ for (i=0;i<=$numRecords;i++) { $num_overpaid[$student_id]++; - //this if-statement allows us to + //this if-statement allows us to determine if a student is on his/her second attempt if ($attempts[$question_id] == 1) { @@ -90,6 +101,12 @@ for (i=0;i<=$numRecords;i++) if($submitted_sum < $correct_sum) { $num_underpaid[$student_id]++; + + //this if-statement allows us to determine if a student is on his/her second attempt + if ($attempts[$question_id] == 1) + { + + } } } } |