Let P be a convex polygon with n vertices. Let q and r be a query points.
a. Assume n = 3 and P has positive area. Describe how to determine efficiently whether exactly one of the points q and r falls inside of P. Analyze how much time is used.
b. Assume that n ≥ 3 and the n vertices of P are stored in an array in clockwise order around P. Describe how to determine efficiently whether exactly one of the points q and r falls within P. Analyze the time for your algorithm