The average of the three grades is given by:

where x is the grade of the final exam.
(a) So, in order to have an average of at least 90, the grade x must be:

Therefore, to earn an A in the course, you must get at least 91 on the final.
(b) If the final average is less than 80, we have:

Therefore, the grades on the final that will cause this to happen are the grades that are less than 61.