Skip to content

Instantly share code, notes, and snippets.

@cmbrownfield
cmbrownfield / gist:cbfb85550da2ba09bb0b5a09888f0276
Created April 28, 2020 21:23
Prolog gensym example (broken)
:- use_module(library(gensym)).
:- dynamic student/3.
gensym:gensym(student, S1).
gensym:gensym(student, S2).
student(S1, john, doe).
student(S2, jane, doe).
show_id_of_john :-
student(ID, john, doe), write(ID).