if not graph.has_key(start): code example
Example: graph.has_key
Removed dict.has_key() – use the in operator instead.
Here's an example:
if start not in graph:
return None
Removed dict.has_key() – use the in operator instead.
Here's an example:
if start not in graph:
return None