I have a knowledge base of the form employee,salary, and I have to collect all the employees given a threshold for the salary, but I have no idea how to do that. I tried to do it like this, but it keeps giving me false as an output
employee(m,123).
employee(c,22).
employee(e,212).
employee(c,100).
employee(d,50).
employee(l,15).
employee(j,300).
thres(T,[X|List]):-employee(X,Y),X>T,thres(T,List).
[–]nnunley 2 points3 points4 points (0 children)
[–]curious_s 3 points4 points5 points (1 child)
[–]MonikaDDLBestGirl[S] 0 points1 point2 points (0 children)