title: Checking whether two vertices are connected
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/684302/how-can-i-search-a-graph-for-a-path">How can I search a graph for a path?</a>  </p>
  </blockquote>
  
  
  
  <p>I was wondering what the best approach was in a 'graph' with objects that do refer to their neighbours, but of whom i also have an overview (a hashmap with objects on coordinates), to determine wether two of these objects are connected.</p>
  
  <p>I read Dijkstra might be unefficient for this and i read up about BFS and DFS.</p>
  
  <p>From my understanding BFS might get close to what i need, can i do better? Is there a more common way of solving this? Maybe even easier? Time complexity does play a role :)</p>