There are two parts of this question and I've managed to do the first part. It's the second part I'm currently having problem with.
1. Create a factbase of students and their CGPA for at least 5 students with CGPA ranging from 2 to 5 with students having the CGPA (4.1) by defining deftemplate facts. The name slot should be STRING type and CGPA slot should be of floating point number.
But how to...
2. Write a rule to find names and their CGPA and display the result on the monitor.
(student (name “A B C”) (CGPA 2.0))
(student (name “D E F”) (CGPA 2.5))
(student (name “G H I”) (CGPA 3.0))
(student (name “J K L”) (CGPA 4.1))
(student (name “M N O”) (CGPA 4.1)))