POJ - 1330 Nearest Common Ancestors(倍增LCA)

裸的求LCA,用的倍增,就是爲了記個模板,似懂非懂,之後有時間就弄懂這些算法(大機率不會了。。。。。。)算法 #include <queue> #include <stdio.h> #include <string.h> using namespace std; const int MAXN = 10010; const int DEG = 20; struct Edge { int
相關文章
相關標籤/搜索