set up an equation and solve each problem