NeverSayNever's blog

By NeverSayNever, history, 8 years ago, In English

Let G be a graph so that for every v, deg(v) ≥ k. Show that G contains a path of length at least k and give an algorithm to find such a path.


Hint: Augment a path from both ends until there are no vertices outside the path, that are joined to the end vertices of the path.

  • Vote: I like it
  • +5
  • Vote: I do not like it

»
8 years ago, # |
  Vote: I like it +18 Vote: I do not like it

Choose any vertex v in the first step. At each subsequent step, choose any random neighbor of the current vertex you are in that has not been visited before. You will get a valid choice for the next vertex for all the first k steps because each vertex has at least k neighbors and less than k vertices have been marked as visited.