To find the total number of questions on Khadija's final exam, we can use the formula for percentage:
\[ \text{Percentage} = \left( \frac{\text{Number of correct answers}}{\text{Total number of questions}} \right) \times 100 \]
In this case, Khadija answered 174 questions correctly and earned a grade of 87%. We can set up the equation:
\[ 87 = \left( \frac{174}{\text{Total number of questions}} \right) \times 100 \]
Next, we can rewrite the equation to solve for the total number of questions:
\[ \frac{174}{\text{Total number of questions}} = \frac{87}{100} \]
Now, cross-multiply to eliminate the fraction:
\[ 174 \times 100 = 87 \times \text{Total number of questions} \]
Calculating the left side:
\[ 17400 = 87 \times \text{Total number of questions} \]
Now, we can solve for the total number of questions by dividing both sides by 87:
\[ \text{Total number of questions} = \frac{17400}{87} \]
Calculating this gives:
\[ \text{Total number of questions} = 200 \]
Thus, the total number of questions on the final exam is \( \boxed{200} \).