Question
You are given two jugs, one measured 5 litre (5L) while the other measure 7 litre (7L). There is a pump with unlimited water for
You are given two jugs, one measured 5 litre (5L) while the other measure 7 litre (7L). There is a pump with unlimited water for filling the jug and the ground which water may be poured. Neither of the jugs has any measuring markings. Both jugs are empty. How can you get exact 3 litre of water into the 7 litre jug and empty 5 litre jug?
Define the state space for this problem
What is the goal state?
What is the initial state?
Given the production rules, shows the workflow trace based on a data-driven approach, complete table 1 by filling the blanks with appropriate values
Production rules Rules State Condition Action Fill 5L jug Fill 7L jug Empty 5L jug on ground Empty 7L jug on ground Rule 1 (x, y) Ifx 0 Rule 4 (x, y) If y> 0 Rule 5 (x, y) If (x+y) 2 5 AND Y> 0 AND X 5 Rule 6 (x, y) If (x+y) 2 7 AND x > 0 AND Y# 7 Rule 7 (x, y) If (x+y) s 5 AND y 20 Rule 8 (x, y) If (x+y) S 7 AND X20 Pour water from 7L to fill 5L jug Pour water from 5L to fill 7L jug Pour all water from 5L to 7L Pour all water from 7L to 5L Table 1 - Complete the table Iteration # Working Memory Current Goal State Conflict Set (Rule #) Fired Rule State 1 2 3 4 6 7
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started