the following Prolog code
person(dana, sawad, female, 40, chemist). person(ahmad, abu_j, male, 53, solicitor). person(suna, jab, female, 39, doctor). person(osama, ahmad, male, 43, architect). person(sara, rami, female, 30, engineer). person(yazan, ali, male, 27, programmer). man(X):-person(X, _, male,_,_). woman(X):-person(X,_, female, _, _). whoisengineer(X):-person(X,_,_,_, engineer). canmarry(X,Y):-man(X),woman(Y),write(X), write(' can marry '), write(Y), nl. cantreat(X,Y):-person(X,_,_,_,doctor),person(Y), write(X), write(' can treat '), write(Y),nl.
query to find whom can treat osama?
query to check if ahmad is a man?
query to find who can marry the engineer?
rule that find all people who exceeds 50 years old, name it Above50().?