From d8e164928845fc42479932f8e119551741734b08 Mon Sep 17 00:00:00 2001 From: lolabird Date: Thu, 29 Feb 2024 14:41:20 -0700 Subject: [PATCH] Add return keyword to recursive call --- thinkcspy/Chapter-16-Exercises/Problem11_crossings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thinkcspy/Chapter-16-Exercises/Problem11_crossings.py b/thinkcspy/Chapter-16-Exercises/Problem11_crossings.py index a68eaf1..45b05b4 100644 --- a/thinkcspy/Chapter-16-Exercises/Problem11_crossings.py +++ b/thinkcspy/Chapter-16-Exercises/Problem11_crossings.py @@ -26,7 +26,7 @@ def cross(rounds, bank1, boat, bank2): print(rounds, bank1, boat, bank2) rounds += 1 - cross(rounds, bank1, boat, bank2) + return cross(rounds, bank1, boat, bank2) def main():