Why does the table stand straight?

If the table is ready, the system is in balance.
So, the sum of the forces affecting it and the rotational inertia is zero. To reach this stability, at least three underpins are needed that are on three different levels.

There are cases, when we can reach balance with objects in a way that we support them only in one point. To do this, we have to support them at their center of mass.

Animals and people, too instinctively find the balanced position.