摘要:
同swustoj 8SnakesTime Limit:1000MSMemory Limit:65536KTotal Submissions:1015Accepted:341DescriptionBuffalo Bill wishes to cross a 1000x1000 square field... 阅读全文
摘要:
一、什么是LCA?LCA:Least Common Ancestors(最近公共祖先),对于一棵有根树T的任意两个节点u,v,求出LCA(T, u, v),即离跟最远的节点x,使得x同时是u和v的祖先。二、算法分类 求LCA的算法很多,按照是否在线可以分为在线算法和离线算法。在线算法:用比较长的时... 阅读全文
摘要:
Submissions of online judge(1021)问题描述An online judge is a system to test programs in programming contests. The system can compile and execute codes, a... 阅读全文
摘要:
K-lucky-number(0917)问题描述K-lucky-number is defined as add up the number of each bit is a multiple of K.for example, 24 is a 3-lucky-number,because 2+4=... 阅读全文
摘要:
3887 - Slim SpanTime limit: 3.000 secondsGiven an undirected weighted graphG, you should find one of spanning trees specified as follows.The graphGis ... 阅读全文