This is a problem where, you have a 3-gallon and a 5-gallon jug that you can fill from a fountain of water. The problem is to fill one of the jugs with exactly 4 gallons of water.
It is resolved with Javascript.
This app was built for the purpose of sharing my knowledge on it, this is explained in my personal Blog.
You can check out this post here.