|
|
back to boardShow all messages Hide all messagesI wrote solution, it works well on my PC, but gives stack overflow 1 on Online judge, first test is example from problem statement, I've no idea, on Visual c++ 2008 my solution does not give any error, please help if you know whats up with Compiler on Timus... --- CODE DELETED Edited by author 13.10.2009 18:32 I think you shouldn't post whole code here. I dont think so ) anyway It is not an AC code and I can put it here. I'll delete code when I will get AC Edited by author 11.10.2009 23:44 found mistake at last :| AC now sz[++nom] = dfs(i , j , nom); this fragment changed to: nom++ sz[nom] = dfs(i , j , nom); do you see any difference? timus compiler sees :) You should study Timus C++ compiler better or write compiler-independent codes ;) Edited by author 13.10.2009 18:36 ... Edited by author 13.10.2009 18:36 ... Edited by author 13.10.2009 18:36 ... Edited by author 13.10.2009 18:35 You should study Timus C++ compiler better or write compiler-independent codes ;) Edited by author 13.10.2009 18:36 I studied that ++x increases x, before making operations on it :) PS. why all the strange things happens with me? :( I lost 1 year of my life debugging my code... :S |
|
|