public void depthFirstTraversal()
    {
        boolean[] visited;  
        
        visited = new boolean[gSize];

        for (int index = 0; index < gSize; index++)
            visited[index] = false;

        for (int index = 0; index < gSize; index++) 
            if (!visited[index])         
                dft(index, visited);      
    }