From d13ab114f86a6358f875a2d9cc9187e2858866b5 Mon Sep 17 00:00:00 2001 From: chenyang929 Date: Wed, 16 May 2018 02:54:59 +0800 Subject: [PATCH] Update 01_breadth-first_search.py (#75) change line 24 to make more pythonic style --- 06_breadth-first_search/python/01_breadth-first_search.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/06_breadth-first_search/python/01_breadth-first_search.py b/06_breadth-first_search/python/01_breadth-first_search.py index c488417..aac8e8c 100644 --- a/06_breadth-first_search/python/01_breadth-first_search.py +++ b/06_breadth-first_search/python/01_breadth-first_search.py @@ -21,7 +21,7 @@ def search(name): while search_queue: person = search_queue.popleft() # Only search this person if you haven't already searched them. - if not person in searched: + if person not in searched: if person_is_seller(person): print person + " is a mango seller!" return True