Walks, Trails, Paths, Cycles and Circuits in GraphWalks, trails, paths, cycles, and circuits in a graph are sequences of vertices and edges with different properties. Some allow repetition of vertices and edges, while others do not. In this article, we will explore these concepts with examples.What is Walk?A walk in a graph is a sequence of vertice
6 min read
Eulerian path and circuit for undirected graphGiven an undirected connected graph with v nodes, and e edges, with adjacency list adj. We need to write a function that returns 2 if the graph contains an eulerian circuit or cycle, else if the graph contains an eulerian path, returns 1, otherwise, returns 0.A graph is said to be Eulerian if it con
9 min read