A fraction can be calculated as the number of whatever we want divided by the total we have.
The total in this case, is the number of questions, which is 10.
The part we want is how many question she asnwered incorrectly.
If she answered 9 correctly, the remaining on is the only she answered incorrectly, so she answer only 1 incorrectly.
This means that the fraction is 1 over 10:
If Patrick got A, which is 9/10, he must have use the number of correct answers instead of incorrect, so in this case he calculated the fraction as 9 over the total 10.