%% tone(Sentence,Tone) /** ?- tone([i,am,happy,with,you],T). T = happy ; **/ tone(Sentence,happy) :- member(happy,Sentence). tone(Sentence,surprise) :- member(surprise,Sentence).