void recur(int now, list < int > :: iterator iter){
  for(int i = 0; i < n; i++)
    if(g[now][i]) g[now][i]--, recur(i, ans.insert(iter, i));
}
// ans.clear(), recur(0, ans.begin());


This topic: Main > ProgrammingContest > Code_EulerCircuit
Topic revision: r3 - 2005-11-18 - MatthewChan
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback