Skip to content

Latest commit

 

History

History
13 lines (10 loc) · 551 Bytes

File metadata and controls

13 lines (10 loc) · 551 Bytes

Challenge Summary

Return a list of nodes hit during a breadth first traversal in the order they were hit

Challenge Description

Extend your graph object with a breadth-first traversal method that accepts a starting node. Without utilizing any of the built-in methods available to your language, return a collection of nodes in the order they were visited. Display the collection.

Approach & Efficiency

Time: O(n^2) Space O(n)

Solution

  • !()[assets/BreadthFirstGraph.jpg]
  • code