About 885,000 results
Open links in new tab
  1. Directed Graph Cycle | Practice | GeeksforGeeks

    Given a Directed Graph with V vertices (Numbered from 0 to V-1) and E edges, check whether it contains any cycle or not.The graph is represented as a 2D vector edges [] [], where each …

  2. Detecting Cycles in a Directed Graph - Baeldung

    Mar 18, 2024 · In this tutorial, we covered one of the algorithms to detect cycles in directed graphs. At first, we discussed one of the important applications for this algorithm.

  3. Cycle (graph theory) - Wikipedia

    A directed cycle in a directed graph is a non-empty directed trail in which only the first and last vertices are equal. A graph without cycles is called an acyclic graph.

  4. Cycle Detection in Directed Graph | by Yogendra | Medium

    Jul 9, 2025 · Understand what cycle detection is, why it's important in system design and dependency graphs, and implement it efficiently in Kotlin with clear explanations and practical …

  5. Cycle Detection in the Directed Graph using the DFS

    Aug 31, 2025 · Cycle detection in a directed graph is a classic algorithm problem and must-know for backend and platform engineers. What is a cycle in a directed graph? The edges of a …

  6. Efficient algorithm for detecting cycles in a directed graph

    Is there an efficient algorithm for detecting cycles within a directed graph? I have a directed graph representing a schedule of jobs that need to be executed, a job being a node and a …

  7. Detect Cycle in a Directed Graph - GeeksforGeeks

    Nov 4, 2025 · To detect a cycle in a directed graph, we use Depth First Search (DFS). In DFS, we go as deep as possible from a starting node. If during this process, we reach a node that …

  8. Cycle Detection in Directed Graph Using DFS - getsdeready.com

    Jun 12, 2025 · Learn how to detect a cycle in a directed graph using DFS with code examples in C++, Java, Python, and JavaScript.

  9. Detect Cycles in Directed Graphs Using BFS (Visualization)

    Oct 3, 2025 · Learn how to detect cycles in directed graphs using BFS with Kahn's algorithm. Includes Python, C++, and Java implementations with complexity analysis.

  10. Detecting cycle in directed graphs using Depth-First-Search (DFS)

    Cycle in directed graphs can be detected easily using a depth-first search traversal. While doing a depth-first search traversal, we keep track of the nodes visited in the current traversal path in …