http://www.cnblogs.com/chendl111/p/7224769.html 题解 树状数组的各个应用 http://www.cnblogs.com/yyf0309/p/7210538.html 改天自己写一遍