How to remove closest game object?

i have 3 game objects with tag “Obj” how to remove closest of them from else game Object?

Vector3.Distance.

get a hold of all the objects you are interested in. you can do this either by finding them all, or by a sphereCast

then taking the distance of each 1 to determine which one is closest