From aca90d8335feea243e919f532d68352adba9e737 Mon Sep 17 00:00:00 2001 From: Kira <38155247+Nyanraltotlapun@users.noreply.github.com> Date: Tue, 30 Dec 2025 16:13:29 +0100 Subject: [PATCH] Small refactor to make code more clean. --- src/get_near_countries.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/get_near_countries.py b/src/get_near_countries.py index 1dbef6c..59dfd02 100755 --- a/src/get_near_countries.py +++ b/src/get_near_countries.py @@ -215,8 +215,8 @@ def main(): if recursion_depth > 12: sys.exit("Recursion should be less than or equal 12! You doing something stupid here.") - result = set(NEAR_COUNTRIES.get(search_country,[])) - for i in range(1, recursion_depth): + result = {search_country} + for i in range(recursion_depth): n_c = list(result) for country in n_c: result.update(NEAR_COUNTRIES.get(country,[]))