Samuelson wrote in "Economics", a "canonical textbook" of mainstream economic thought that "the price mechanism, working through supply and demand in competitive markets, operates to (simultaneously) answer the three fundamental problems in a mixed private enterprise system..." At competitive equilibrium, the value society places on a good is equivalent to the value of the resources given up to produce it (marginal benefit equals marginal cost). This ensures allocative efficiency-the additional value society places on another unit of the good is equal to what society must give up in resources to produce it.