Two Milkmen of Sam Loyd

  1. It was the daily practice of a milkman to fill his two sixteen-gallon cans with pure milk before he started out to serve customers on four different streets, th e same number of quarts being delivered on each street.
    After serving the first street, he connected with the city water supply and, lo, his cans were again filled to the brim! Then he served street number two [the same number of quarts as the first street] and again backed up to the fount to replenish his cans as before.
    He proceeded in this way to serve the third and fourth streets. If forty quarts and one pint of pure milk remained in the cans after all his customers were attended to, how much pure milk must have been delivered on each of the four streets?
    [KD: There's no trick here, just pure math. Four quarts in a gallon, and two pints in a quart.]

  2. Two ladies each asked Honest John for two quarts of milk. One lady had a five-quart pail and the other had a four-quart pail. John had only two ten-gallon cans, each full of milk. How did he measure out exactly two quarts of milk for each lady? [KD: And what's the smallest number of pourings needed?]

Source: Mathematical Puzzles of Sam Loyd, 1960, #5, #23.


Solutions were received from many people: Kirk Bresniker, Denis Borris, Larry Baum, Sandy Thompson, Al Zimmermann, Philippe Fondanaiche.
  1. From Denis Borris:
    Part 1 ; in pints: 64 48 36 27.
    
    Seems like Sam Loyd probably worked in a bank; the puzzle
    is a "re-wording" of what happens to a savings account
    being credited regularly with interest; the value of such
    easily determined at any period n with the most basic of
    the financial formulae: F = P(1 + i)^N, where:
    F = Future value od account
    P = Present Value (or the initial deposit)
    N = Number of periods (coincides with the interest credits)
    i = the periodic interest rate
    
    To stay in the milk business, I'll change the formula to:
    B = E(1 + m)^D [B = milk at Beginning, E = milk at End,
    m = the milk "rate" delivered, D = the number of Deliveries).
    
    Now since we're looking for the milk delivered, then
     m = (B / E)^(1 / N) - 1;
    since our milkman starts with 256 pints, ends with 81 pints:
     m = (81 / 256)^(1 / 4) - 1 = -25% (a poor savings account!);
    
    Looking at it in "bank statement format":
                 Milk  Milk left
     Begin               256
     D #1         -64    192
     D #2         -48    144
     D #3         -36    108
     D #4 (End)   -27     81
    
    Of course, we can go in reverse (switch B and E) to
    get a milk rate of 33 1/3%, which really means a Beginning
    milk deposit of 81 pints earning milk at a rate of 33 1/3%:
                 Milk  Milk left
     Begin                81
      #1          27     108
      #2          36     144
      #3          48     192
      #4          64     256
    
    Really, all "kinds of scenarios" can be worked out;
    example: if we try D = 6 in above formula, we get an
    Ending amount of 15.1875 pints; so to "integerize(?)" 
    the scenario, you simply start with 2,560,000 pints, 
    your 6 deliveries being:
    640000 480000 360000 270000 202500 151875.
    

  2. MANY people found a 9 move solution for this. Kirk Bresniker and Denis Borris found a 2 move solution. Denis explains it below, then shows the 9-move solution as well:
    Part 2: 2 moves.
     Since the 4quart pail is symmetrical,    4quart
     (puzzle doesn't say it isn't), then     .     .A
     Honest John can do it in 2 moves:       .     .
     (if he's not shaking from a hangover!)  .     .
     1- fill the 4quart pail                B.......
     2- pour milk into the 5quart pail by
        tilting the 4quart pail, until a
        new milk level AB is created.
    
    But I'm sure I won't get a passing mark for that, so
    here's how I did it in 9 moves; for those interested
    who may want to buy 1 or 3 quarts, here you go too:
    move ten ten five four   ten ten five four   ten ten five four 
      1  10   5   5    0     10   5   5    0     10   5   5    0
      2  10   5   1    4     10   5   1    4     10   5   1    4
      3  10   9   1    0     10   9   1    0     10   9   1    0
      4   6   9   1    4     10   9   0    1      6   9   1    4
      5   7   9   0    4     10   4   5    1      7   9   0    4
      6   7   9   4    0     10   4   2    4      7   9   4    0
      7   7   8   5    0     10   8   2    0      3   9   4    4
      8   7   8   1    4      6   8   2    4      3   9   5    3 
      9  10   8   1    1      6  10   2    2      8   9   0    3
     10                                           8   4   5    3
     11                                          10   4   3    3 
    
    unless someone can beat 11 for 3 quarts, sorry you 3quarters
    but you'll have to wait a little longer.
    
    [KD: A note on the above: Denis mixes the values for quarts and gallons. In essence, he's replaced the 10-gallon (40-quart) with 10-quart containers, but the underlying math still works, since it's just subtracting from their total volume.]
    Mail to Ken