摘要:
我们在升级mongodb3.6之后,线上数据库存在大量慢查询,经过分析explain结果发现是query plan阶段耗时过长,于是我先研究了下mongodb3.6的query plan。 query plan机制 现有索引: { "key" : { "c1" : 1.0 }, "name" : " 阅读全文
摘要:
Description Edward is the headmaster of Marjar University. He is enthusiastic about chess and often plays chess with his friends. What's more, he bought a large decorativ... 阅读全文
摘要:
Description 吉哥又想出了一个新的完美队形游戏! 假设有n个人按顺序站在他的面前,他们的身高分别是h[1], h[2] ... h[n],吉哥希望从中挑出一些人,让这些人形成一个新的队形,新的队形若满足以下三点要求,则就是新的完美队形: 1、挑出的人保持原队形的相对顺序不变,且必须... 阅读全文
摘要:
Manacher算讲解:(讲得很好,花十几分钟看一下原理然后自己敲模板) http://www.cnblogs.com/biyeymyhjob/archive/2012/10/04/2711527.html 看了上面的讲解,O(n)回文子串(Manacher)算法就大致了解了它的原理,这倒是个比较简单的知识点。 下面看模板题: Desc... 阅读全文
摘要:
Description Hzz loves aeroplane chess very much. The chess map contains N+1 grids labeled from 0 to N. Hzz starts at grid 0. For each step he throws a dice(a dice have si... 阅读全文
摘要:
Description I used to think I could be anything, but now I know that I couldn't do anything. So I started traveling. The nation looks like a connected bidirecti... 阅读全文
摘要:
Description In the battlefield , an effective way to defeat enemies is to break their communication system. The information department told you that there are n... 阅读全文
摘要:
Description For the hope of a forever love, Steven is planning to send a ring to Jane with a romantic string engraved on. The string's length should not exceed N. The car... 阅读全文
摘要:
Description Biologists finally invent techniques of repairing DNA that contains segments causing kinds of inherited diseases. For the sake of simplicity, a DNA is represe... 阅读全文
摘要:
Description There is going to be a party to celebrate the 80-th Anniversary of the Ural State University. The University has a hierarchical structure of employees. It mea... 阅读全文