摘要: #include<iostream> #include<cstring> #include<cstdio> #include<algorithm> #include<queue> #include<cmath> #include<vector> #define maxn 40005 #define 阅读全文
posted @ 2019-09-27 23:37 MXR_alone 阅读(160) 评论(0) 推荐(0) 编辑
摘要: #include<iostream> #include<cstring> #include<cstdio> #include<algorithm> #include<queue> #include<cmath> #include<vector> #define maxn 3005 #define r 阅读全文
posted @ 2019-09-22 22:58 MXR_alone 阅读(146) 评论(0) 推荐(0) 编辑
摘要: #include<iostream> #include<cstring> #include<cstdio> #include<algorithm> #include<queue> #include<cmath> #include<vector> #define maxn 305 #define ri 阅读全文
posted @ 2019-09-20 19:16 MXR_alone 阅读(140) 评论(0) 推荐(0) 编辑
摘要: 题目链接:https://www.luogu.org/problem/P5002 题解: 假设我们找到点u 1.这些点对不跨越u,即其中有一个点一定是u \[ans1 = 2 \times size\left[ u \right] - 1\] 2.这些点不跨越u u的所有子树的大小相乘即是答案。w为 阅读全文
posted @ 2019-08-07 19:21 MXR_alone 阅读(118) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2019-08-06 23:21 MXR_alone 阅读(3) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2019-08-04 22:08 MXR_alone 阅读(3) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2019-08-02 19:10 MXR_alone 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 先看一道poj上的题目:【poj1006】 Biorhythms 题意: 人自出生起就有体力,情感和智力三个生理周期,分别为23,28和33天。一个周期内有一天为峰值,在这一天,人在对应的方面(体力,情感或智力)表现最好。通常这三个周期的峰值不会是同一天。现在给出三个日期,分别对应于体力,情感,智力 阅读全文
posted @ 2019-03-23 11:13 MXR_alone 阅读(305) 评论(0) 推荐(0) 编辑
摘要: 1.组合数公式 C(n,m)=C(n,n-m) 感性理解。。。 2.组合数递推公式 C(n,m)=C(n-1,m-1)+C(n-1,m) 等式左边表示从n个元素中选取m个元素,而等式右边表示这一个过程的另一种实现方法:任意选择n中的某个备选元素为特殊元素,从n中选m个元素可以由此特殊元素的分成两类情 阅读全文
posted @ 2019-03-13 15:00 MXR_alone 阅读(2158) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2019-03-13 14:51 MXR_alone 阅读(2) 评论(0) 推荐(0) 编辑