diff --git a/dfs.cc b/dfs.cc index 4919fb8..c7d9535 100644 --- a/dfs.cc +++ b/dfs.cc @@ -24,17 +24,17 @@ #include class node { -public: + public: node(std::string const &name) : name_(name) {} void add_child(class node *n) - { - children_.push_back(n); - } + { + children_.push_back(n); + } void dfs(std::list &res); bool visited; -private: + private: std::string const name_; std::list children_; };