REM Test knowledge base RULE [Is the battery dead?] If [the result of switching on the headlights] = "nothing happens" or [the result of trying the starter] = "nothing happens" Then [the recommended action] = "recharge or replace the battery" RULE [Is the car out of gas?] If [the gas tank] = "empty" Then [the recommended action] = "refuel the car" RULE [Is the battery weak?] If [the result of trying the starter] : "the car cranks slowly" "the car cranks normally" and [the headlights dim when trying the starter] = true and [the amount you are willing to spend on repairs] > 24.99 Then [the recommended action] = "recharge or replace the battery" RULE [Is the car flooded?] If [the result of trying the starter] = "the car cranks normally" and [a gas smell] = "present when trying the starter" Then [the recommended action] = "wait 10 minutes, then restart flooded car" RULE [Is the gas tank empty?] If [the result of trying the starter] = "the car cranks normally" and [a gas smell] = "not present when trying the starter" Then [the gas tank] = "empty" @ 90 PROMPT [the result of trying the starter] Choice CF "What happens when you turn the key to try to start the car?" "the car cranks normally" "the car cranks slowly" "nothing happens" PROMPT [a gas smell] MultChoice CF "The smell of gasoline is:" "present when trying the starter" "not present when trying the starter" PROMPT [the result of switching on the headlights] MultChoice CF "The result of switching on the headlights is:" "they light up" "nothing happens" PROMPT [the headlights dim when trying the starter] YesNo CF "Do the headlights dim when you try the starter with the lights on?" PROMPT [the gas tank] MultChoice CF "According to the fuel gauge, the gas tank is:" "empty" "not empty" PROMPT [the amount you are willing to spend on repairs] Numeric CF "How much are you willing to spend on repairs? (enter value 0->500)" "0" "500.0" GOAL [the recommended action] MINCF 80