From 522e9b35efcbd830561abe28babc66e57da54f98 Mon Sep 17 00:00:00 2001 From: Krzysztof Rudnicki Date: Sun, 4 Jun 2023 14:02:03 +0200 Subject: [PATCH] feat: add code --- code/main.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/main.pl b/code/main.pl index 3b899b2d..c5876d1e 100644 --- a/code/main.pl +++ b/code/main.pl @@ -1,7 +1,8 @@ % month_days(Month, DaysInMonth, DaysBeforeMonth) % returns the number of days in Month and the number of days it takes to reach that date in year 2023 % prolog works by defining facts and rules and when queried about them returns values -% it works different from functional programming in this aspect since it doesn't just follow instruction it returns output based on world state +% it works different from functional programming in this aspect since it +% doesn't just follow instruction it returns output based on world state month_days('01', 31, 0). month_days('02', 28, 31). month_days('03', 31, 59).