Question d’entretien chez Autodesk

How to detect a cycle in a graph?