How is weight distributed in a stack of boxes? Consider the following stacks of 2D boxes with uniform density:
      A                   B                        C
 ___________          _________                _________
|           |        |         |              |         |
|___________|     ___|_________|____     _____|_________|___
|   |   |   |    |        |   |     |   |        |     |     |
|___|   |___|    |________|   |_____|   |________|     |_____|

How is the weight of the boxes on top distributed to the lower ones?
A) 50:50
B) Theoretically 100:0, since I can just get rid of the lower right box because the center of mass of the top box is just above the edge of the lower left one?
C) ?
Is there an equation or algorithm to calculate this?
 A: This question is very difficult to answer because the second system will respond in a non-linear fashion.
Imagine for the second image that instead of the right block resting on the ground that you replace it with a piston that can supply a variable force.  
If we reduce the force to only the weight of the lower block, as you notice the upper block will not move because the left block supports it entirely.  But if we increase the force a bit, it still doesn't change.  The upper block becomes more supported on the right in (almost) the exact same physical configuration.  So both weight distributions are consistent with the image.
In the limit where the block surfaces are perfectly smooth and exactly flat, the solution is ambiguous.  You can draw multiple different FBD diagrams where weight and torque are in equilibrium via forces were surfaces touch.
In practice, microscopic differences in the surface would lead to significant differences in the weight distribution.  
A: Tl;dr @BowlOfRed's answer is correct, theoretical task has infinite number of solutions, but I can't resist giving my way of explaining it using mad paint skills.
Before rushing to solve boxes problem, lets start with something extremely simpler. Consider ideal pole resting on two ideal points (no friction, no deformation, insignificant area of contact etc) and try finding weight distribution. Not a big deal, isn't it? Pole has zero acceleration so sum of forces is zero, zero angular acceleration, so total torque is zero, this two equations give value of forces applied by points depending on their position like drawn on the pict

Great, but what if we have three points?

Solution where one point apply zero force and other two behave as if it's two-point-case is still valid. Moreover, there are infinite number of solutions, where all three points are applying force.

That happens, because you still have two equations as before, but there is three variables to find. So they are tied, but can use arbitrary value from some range.
So even if left box had only two points of contact with upper one and right box had only one point of contact, we wouldn't be able to solve such task. Actual boxes are obviously more complicated, because contact area isn't zero and it's like having infinite amount of points to distribute weight among with no info about distribution type. However, you still can find max and min force applied by each box by considering corner cases. E.g. for case B max force applied to left box is obviously full weight of the upper box, but min force can be found from assumption, that left and upper box interact as if the only point of contact is the leftmost point (corner) of the upper box (so force distribution is weird, it's zero in all points except for farthest from center) and the right box use its leftmost corner to apply full force.
A: The solution is torque.
Obviously, the total force exerted by the lower boxes is equal to the weight of the top box, since it does neither accelerate up or down.
But additionally, the torque also needs to be in equilibrium, since the top box also does not start to rotate. Using this second equation, you can calculate the force exacted by the individual boxes.
