主题:[讨论]狼羊白菜
狼羊白菜过河问题啊!!!!!求救了啦22!!!!!·
要求如下:最终输出结果格式:
east:farmer goat wolf cabbage west:none
The 1 time
-------->farmer and goat
east:wolf cabbage west:farmer goat
<----------farmer
east:farmer wolf cabbage west:goat
The 2 time
--------->farmer and wolf
east:cabbage west:farmer goat wolf
<--------farmer and goat
east:farmer goat cabbage west:wolf
east:none west:farmer goat wolf cabbage
要求如下:最终输出结果格式:
east:farmer goat wolf cabbage west:none
The 1 time
-------->farmer and goat
east:wolf cabbage west:farmer goat
<----------farmer
east:farmer wolf cabbage west:goat
The 2 time
--------->farmer and wolf
east:cabbage west:farmer goat wolf
<--------farmer and goat
east:farmer goat cabbage west:wolf
east:none west:farmer goat wolf cabbage