kdrag.solvers.prolog.run_string

kdrag.solvers.prolog.run_string(s: str)

Run a Prolog-like string and return the results.

>>> run_string("plus(z, Y, Y). plus(s(X), Y, s(Z)) :- plus(X, Y, Z). ?- plus(X, Y, s(z)).")
[([], {Y: s(z), X: z}), ([], {X: s(z), Y: z})]
Parameters:

s (str)