yshshrm / Data-Structures-And-Algorithms-Hacktoberfest18

List of data structures and algorithms. Feel free to contribute under Hacktoberfest '18!
204 stars 1.1k forks source link

Detect cycle in a directed graph #1717

Open atishayzn opened 3 years ago

atishayzn commented 3 years ago

Given a Directed Graph with V vertices (Numbered from 0 to V-1) and E edges, check whether it contains any cycle or not.