/* -*- prolog -*- ********************* FARMER, WOLF, GOAT, CABBAGE ******************** File: farmer.pl Description: Farmer, wolf, goat, cabbage problem from luger & stubblefield, p. 228ff. This is a production system version of the problem.
Category:
move(state(X,W,X,C), state(Y,W,Y,C)):- opp(X,Y), not(unsafe(state(Y,W,Y,C))), writelist(['try farmer takes goat ', Y, W, Y, C]), nl. move(state(X,W,G,X), state(Y,W,G,Y)):- opp(X,Y), not(unsafe(state(Y,W,G,Y))), writelist(['try farmer takes cabbage ', Y, W, G, Y]), nl.
Category:
Cutworms, imported cabbage worm, cabbage looper, diamondback moth larvae, and cross-striped cabbage worm can be early season pests of cabbage. These pests can cause serious damage to young transplants as well as causing serious leaf feeding damage to older plants.
Category: