Farmer Joe 1.5

Logic Level 2

Farmer Joe had a fox, a chicken, and some chicken feed with him. While coming back from the town village, he had to cross a river in order to get home. The only way home is on a small boat which can only hold Farmer Joe and one of the three items. If the fox is left with the chicken, the fox will eat the chicken. If the chicken is left with the chickenfeed, the chicken will eat the chickenfeed. How can Farmer Joe bring all three items across the river without any of the items being harmed? Farmer Joe can bring items back and forth from shore to shore, i.e., he brings the fox to one side of the river, then brings him back to the other side again. In the answer, 1= Chicken, 2= Fox, and 3=Chickenfeed.

13213/12131 13121/12132 13121/21312 12213 12131/13121

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

2 solutions

Maxwell DiPillo
Jul 9, 2019

Since the fox can be trusted with the chickenfeed, you bring the chicken over first. Then, you can either bring over the fox or the chickenfeed, since there will be only one item left at the shore. From there, after bringing over either the fox or the chickenfeed, you then bring the chicken back over because the chicken can't be trusted with either the fox or the chickenfeed. From there, you bring over either the fox or the chickenfeed depending on which you brought over first, and then finally you bring over the chicken one last time.

Richard Desper
Jul 10, 2019

The question could use some explanation about the coding. Or you could add an option for "Joe brings nothing" = 0. In which case the answer would be 1021301/1031201.
Basically the solution is a greedy algorithm constrained on not leaving the chicken on a bank with either the fox or the feed.

I would implement this into the problem, but I don't know how I would change the answer to the problem. It doesn't come up as an option anywhere when I go to edit the problem if I wanted to change the answer. You wouldn't happen to know how I could change the answer to the problem? Or do I just have to delete the whole problem if I want to just revise the answer?

Maxwell DiPillo - 1 year, 11 months ago

1 pending report

Vote up reports you agree with

×

Problem Loading...

Note Loading...

Set Loading...