Question: An Euler tour of a directed graph G with n vertices and m edges is a cycle that traverses each edge of G exactly once

An Euler tour of a directed graph G with n vertices and m edges is a cycle that traverses each edge of G exactly once according to its direction. Such a tour always exists if G is connected and the in-degree equals the out-degree of each vertex in G. Describe an O(n+m)-time algorithm for finding an Euler tour of such a directed graph G.

Step by Step Solution

3.34 Rating (166 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Pseudo code Step1 Chose a starting vertex v arbitrarily Step2 Search a cycle C starting and ending a... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Introduction to Algorithms Questions!