pts = {{0, 0}, {1, -1}, {1, 1}, {4, 0}}

How to use Mathematica code to reorder the coordinates of any four given points so that they are arranged (either clockwise or counterclockwise) as the four points of a closed quadrilateral as follows and so on. The polygon drawn with the reordered coordinates is shown in the right-hand panel above.
{{0, 0}, {1, -1}, {4, 0}, {1, 1}}
Or
{{1, -1}, {4, 0}, {1, 1}, {0, 0}}
Or
{{4, 0}, {1, 1}, {0, 0}, {1, -1}}
Extending the above problem: suppose we are given n arbitrarily ordered points that are known to form a simple closed n-gon; how can we reorder them—clockwise or counter-clockwise—so that the list can be used to plot the polygon correctly and compute its area?The purpose is to make the code universal.