Manhatten and Queries [Need Help]

Hello all , I need one help , we have N coordinates given, and we have Q queries of a given point find the min or max Manhatten distance with a point in each query

No update query only answer query .

for each query my approach is O(N) , obviously, I tried to read the below links but was not able to find what I have to do.

Link1 - c++ - Given a set of points, find the one that has the smallest Manhattan distance from a query point - Stack Overflow

Link2 - MDIST - Editorial

@ssjgz @cubefreak777 @nichke