Hacker News new | ask | show | jobs
by gregw134 1071 days ago
It figures it out once you let it reflect on its answer: Consider the following situation: You have a 12 liter jug and a 6 liter jug, and you want to measure out exactly 6 liters of water. First, generate an initial solution for this problem. Then, think about the solution you've generated, considering if there might be a simpler or more straightforward way to achieve the goal. If there is, please provide the more accurate or simpler solution.
1 comments

Interesting approach. 3.5 gave me this as its second answer:

1. Fill the 6 liter jug to its maximum capacity. 2. Pour the contents of the 6 liter jug into the 12 liter jug, which will leave 6 liters in the 6 liter jug. 3. You have now measured out exactly 6 liters of water using the 6 liter jug.

Yeah 3.5 still can't figure it out, 4 does though. Hilariously 3.5 gave me this:

Fill the 6-liter jug completely with water. Pour the water from the 6-liter jug into the 12-liter jug. Fill the 6-liter jug again with water. Pour water from the 6-liter jug into the 12-liter jug until the 12-liter jug is full. This leaves 4 liters of water in the 6-liter jug. Empty the 12-liter jug. Pour the 4 liters of water from the 6-liter jug into the empty 12-liter jug. Fill the 6-liter jug with water again. Pour water from the 6-liter jug into the 12-liter jug until the 12-liter jug is full. This leaves exactly 6 liters of water in the 12-liter jug.