1. Maintain an inner hash table to look up name duplicates. O(1) a. Name of city hashes to int that stores current distance 2. Don't instantiate (`new *node`) until absolutely necessary. Should be all that is needed.