This is code for generating cities based on  breadth first search.