we start with a mother (m), two daughters (d1, d2), a father (f), two sons (s1, s2), a housemaid (h), and a dog (c – canine) assume on the west (W) shore, and they all want to get to the east (E) shore.
W = {m, d1, d2, f, s1, s2, h, c} // everyone on the west shore
E = {} // no one on the east shore
let’s move everyone, over…
housemaid and dog (canine(c)) go east, and the housemaid comes back:
W = {m, d1, d2, f, s1, s2, h}
E = {c}
housemaid and s1 go east, h and c come back:
W = {m, d1, d2, f, s2, h, c}
E = {s1}
father and s2 go east, father comes back:
W = {m, d1, d2, f, h, c}
E = {s1, s2}
mother and father go east, mother comes back:
W = {m, d1, d2, h, c}
E = {f, s1, s2}
h and c go east, father comes back:
W = {m, d1, d2, f}
E = {s1, s2, h, c}
father and mother go east, mother comes back:
W = {m, d1, d2}
E = {f, s1, s2, h, c}
mother and d1 go east, housemaid and c come back:
W = {d2, h, c}
E = {m, d1, f, s1, s2}
h and d2 go east, h comes back
W = {h, c}
E = {m, d1, d2, f, s1, s2}
h and c go east
W = {}
E = {m, d1, d2, f, s1, s2, h, c}
done!