From a3a234529b30aa62470f5159d5e8848d15d06bdb Mon Sep 17 00:00:00 2001 From: Dyuman Date: Thu, 25 Jan 2024 17:05:27 +0530 Subject: [PATCH] Updated Hello world example --- docs/hello-world.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/hello-world.py b/docs/hello-world.py index 61c6b1d5..e2c4b379 100644 --- a/docs/hello-world.py +++ b/docs/hello-world.py @@ -32,7 +32,7 @@ # Load all rules and the graph into pyreason # Someone is "popular" if they have a friend who is popular and they both own the same pet pr.load_graph(g) -pr.add_rule('popular(x) <-1 popular(y), Friends(x,y), owns(y,z), owns(x,z)', 'popular_rule') +pr.add_rule(pr.Rule('popular(x) <-1 popular(y), Friends(x,y), owns(y,z), owns(x,z)', 'popular_rule')) pr.add_fact(pr.Fact('popular-fact', 'Mary', 'popular', [1, 1], 0, 2))