{"id":1168,"date":"2019-06-15T16:05:31","date_gmt":"2019-06-15T08:05:31","guid":{"rendered":"https:\/\/0.mnihyc.com\/blog\/?p=1168"},"modified":"2020-02-09T02:42:47","modified_gmt":"2020-02-08T18:42:47","slug":"yzoj-p3033-%e8%83%8c%e5%8c%85","status":"publish","type":"post","link":"https:\/\/0.mnihyc.com\/blog\/archives\/1168","title":{"rendered":"YZOJ P3033 \u80cc\u5305"},"content":{"rendered":"<h1 style=\"text-align: center;\">YZOJ P3033 \u80cc\u5305<\/h1>\n<p style=\"text-align: center;\">\u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB<\/p>\n<p style=\"text-align: center;\">\u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a<span style=\"color: #ff9900;\">\\(5.4\\)<\/span><\/p>\n<ul>\n<li>\n<h3><strong>\u9898\u76ee\u63cf\u8ff0<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u5b58\u5728 \\(n\\) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c \\(i\\) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a \\(a_i\\) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 \\(b_i\\) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a \\(0\\) \u4ef6\uff09\uff0c\u5f97\u5230\u7684\u603b\u4ef7\u503c\u4e3a \\(9\\) \u7684\u500d\u6570\u7684\u65b9\u6848\u3002<\/p>\n<p>\u9700\u8981\u5206\u522b\u8ba1\u7b97\u6bcf\u79cd\u7269\u54c1\u4e2d\uff0c\u6bcf\u4ef6\u4e4b\u95f4\u6709\u533a\u522b\u7684\u65b9\u6848\u6570\u548c\u6ca1\u6709\u533a\u522b\u7684\u65b9\u6848\u6570\u3002<\/p>\n<p>\uff08\u5373\u6bcf\u79cd\u7269\u54c1\u6309\u7167 \\(1,2,3, \\cdots ,b_i\\) \u7f16\u53f7\u7684\u65b9\u6848\u6570\u548c\u4e0d\u7f16\u53f7\u7684\u65b9\u6848\u6570\u3002\uff09<\/p>\n<ul>\n<li>\n<h3><strong>\u8f93\u5165\u683c\u5f0f<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u7b2c\u4e00\u884c\u8f93\u5165\u4e00\u4e2a\u6570 \\(n\\) \u3002<\/p>\n<p>\u63a5\u4e0b\u6765 \\(n\\) \u884c\uff0c\u6bcf\u884c\u4e24\u4e2a\u6570 \\(a_i, b_i\\) \u3002<\/p>\n<ul>\n<li>\n<h3><strong>\u8f93\u51fa\u683c\u5f0f<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u8f93\u51fa\u5171\u4e24\u884c\uff0c\u6bcf\u884c\u5404\u5305\u62ec\u4e00\u4e2a\u6570\uff0c\u5206\u522b\u8868\u793a\u5bf9\u4e8e\u6bcf\u79cd\u7269\u54c1\u89c6\u4e3a\u4e0d\u540c\u7684\u65f6\u7684\u65b9\u6848\u6570\u548c\u89c6\u4e3a\u76f8\u540c\u7684\u65f6\u7684\u65b9\u6848\u6570\u3002\u6709\u7684\u65f6\u5019\u65b9\u6848\u6570\u53ef\u80fd\u5f88\u5927\uff0c\u4f60\u9700\u8981\u5c06\u5b83\u5bf9 \\(10^9+7\\) \u53d6\u6a21\u3002<\/p>\n<p>\u65b9\u6848\u6570\u5747\u4e0d\u8003\u8651\u987a\u5e8f\uff0c\u5982 \\(2, 3, 4\\) \u548c \\(4, 3, 2\\) \u662f\u540c\u4e00\u79cd\u65b9\u6848\u3002<\/p>\n<p>\u5982\u679c\u65e0\u6cd5\u505a\u5230\u5219\u8f93\u51fa \\(0\\) \u3002<\/p>\n<ul>\n<li>\n<h3><strong>\u6837\u4f8b\u8f93\u5165<\/strong><\/h3>\n<\/li>\n<\/ul>\n<pre class=\"lang:default decode:true\">2\r\n2 3\r\n3 3<\/pre>\n<ul>\n<li>\n<h3><strong>\u6837\u4f8b\u8f93\u51fa<\/strong><\/h3>\n<\/li>\n<\/ul>\n<pre class=\"lang:default decode:true \">4\r\n2<\/pre>\n<ul>\n<li>\n<h3><strong>\u6837\u4f8b\u8bf4\u660e<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u4e0d\u8003\u8651\u540c\u79cd\u7269\u54c1\u4e4b\u95f4\u7684\u533a\u522b\uff0c\u4e00\u5171\u6709 \\(2\\) \u79cd\u4e0d\u540c\u7684\u65b9\u6848\u51d1\u51fa \\(9\\) \u7684\u500d\u6570\uff0c\u5373 \\(3, 2, 2, 2\\) \u548c \\(3, 3, 3\\) \u3002<\/p>\n<p>\u8003\u8651\u540c\u79cd\u548c\u679c\u5b50\u7684\u533a\u522b\u65f6\uff0c\u4e00\u5171\u6709 \\(C_3^1 \\times C_3^3 = 3\\) \u79cd\u4e0d\u540c\u7684\u65b9\u6848\u51d1\u51fa \\(3, 2, 2, 2\\)\uff0c\\(C_3^3=1\\) \u79cd\u65b9\u6848\u51d1\u51fa \\(3, 3, 3\\)\uff0c\u56e0\u6b64\u603b\u5171\u6709 \\(4\\) \u79cd\u65b9\u6848\u3002<\/p>\n<ul>\n<li>\n<h3><strong>\u6570\u636e\u89c4\u6a21\u4e0e\u7ea6\u5b9a<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u5bf9\u4e8e \\(40\\%\\) \u7684\u6570\u636e\uff0c\\(n \\le 1000 , a_i \\le 100 , b_i \\le 100\\) \u3002<\/p>\n<p>\u5bf9\u4e8e \\(100\\%\\) \u7684\u6570\u636e\uff0c\\(1 \\le n \\le 10^5 , 1 \\le a_i \\le 90000 , 1 \\le b_i \\le 90000\\)<\/p>\n<p>\u3002<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><!--more--><\/p>\n<hr \/>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>\u9996\u5148\u5982\u679c\u6bcf\u79cd\u7269\u54c1\u6ca1\u6709\u533a\u522b\u7684\u8bdd\uff0c\u90a3\u5c31\u662f\u4e00\u4e2a<strong>\u6a21\u610f\u4e49<\/strong>\u4e0b\u7684\u8ba1\u6570\u80cc\u5305\u95ee\u9898\uff0c\u53ef\u4ee5\u6709\uff1a<\/p>\n<p><span style=\"font-size: 20px;\">\\(f_{i, j} = \\sum\\limits_{k=0}^{b_i}{f_{i-1, \\left(j-k \\times a_i\\right) \\% 9}}\\)<\/span> \uff0c\u65f6\u95f4\u590d\u6742\u5ea6\u4e3a \\(O\\left(9n\\max\\{b_i\\}\\right)\\) \u3002<\/p>\n<p>\u6ce8\u610f\u5230 \\(\\left(j-k \\times a_i\\right) \\% 9\\) \u662f\u6709\u5faa\u73af\u6027\u7684\uff0c\u6240\u4ee5\u5206\u7c7b\u5408\u5e76\u4e00\u4e0b\u5c31\u53ef\u4ee5\u505a\u5230 \\(O\\left(9^2n\\right)\\) \u3002<\/p>\n<p>\uff08\u4ee3\u7801\u5927\u6982\u662f\u8fd9\u4e2a\u6837\u5b50\u7684\uff1a<\/p>\n<pre class=\"lang:default decode:true \">inline void ComputeAns(int&amp;f,const int lf[],register int j,register int i)\r\n{\r\n\tregister int loop=(b[i]+1)\/9;\r\n\tif(loop)\r\n\t\tfor(register int k=0;k&lt;9;k++)\r\n\t\t\t(f+=(long long)lf[(j - k*a[i]%9 + 9) %9]*loop%MOD)%=MOD;\r\n\t\r\n\tregister int left=(b[i]+1)%9;\r\n\tfor(register int k=0;k&lt;left;k++)\r\n\t\t(f+=lf[(j - k*a[i]%9 + 9) %9])%=MOD;\r\n}<\/pre>\n<p>&nbsp;<\/p>\n<p>\u73b0\u5728\u95ee\u9898\u662f\u6bcf\u79cd\u7269\u54c1\u4e0d\u540c\u7684\u65b9\u6848\u6570\u5982\u4f55\u8ba1\u7b97\u3002<\/p>\n<p>\u63a8\u4e00\u4e0b\u5f0f\u5b50\u4f1a\u53d1\u73b0\u6211\u4eec\u9700\u8981\u8ba1\u7b97 \\(C_n^9 + C_n^{18} + C_n^{27} + \\cdots\\) \uff0c\u8fd9\u4e2a\u4e1c\u897f\u3002\u3002\u3002\u3002\u3002\u3002<\/p>\n<p>\u7b97\u4e86\u5427\uff0c<code>OEIS<\/code> \u4e0a\u90fd\u6ca1\u6709\u8fd9\u4e2a\u6570\u5217\u7684\u7ebf\u6027\u8ba1\u7b97\u65b9\u6cd5\u3002<\/p>\n<p>\u8003\u8651\u6362\u4e00\u79cd\u601d\u8def\uff0c\u628a\u6bcf\u79cd\u7269\u54c1\u90fd\u62c6\u6210 \\(b_i\\) \u4ef6\uff0c\u7136\u540e\u8003\u8651 DP \u7684\u8f6c\u79fb\u3002<\/p>\n<p>\u628a\u88ab\u52a8\u8f6c\u79fb\u53d8\u6210\u4e3b\u52a8\u8f6c\u79fb\uff0c\u90a3\u4e48\u4e00\u79cd\u7269\u54c1\u7684\u8f6c\u79fb\u5176\u5b9e\u5c31\u662f <span style=\"font-size: 20px;\">\\(f_{i, j} \\to f_{i+1, j},\\ f_{i, j} \\to f_{i+1, \\left(j+a_i\\right) \\% 9}\\)<\/span>\u3002<\/p>\n<p>\u6ce8\u610f\u5230\u53ef\u4ee5\u628a\u8fd9\u6837\u7684\u8f6c\u79fb\u5199\u6210<strong>\u77e9\u9635<\/strong>\u7684\u5f62\u5f0f\uff0c\u5e76\u4e14\u6b64\u77e9\u9635\u4e3a<strong>\u5faa\u73af\u77e9\u9635<\/strong>\u3002<\/p>\n<p>\u6bd4\u5982 \\(a_i=3\\) \uff0c\u90a3\u4e48\u6709\uff1a<\/p>\n<p><span style=\"font-size: 20px;\">\\(\\begin{bmatrix} 1 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 \\\\\u00a0 0 &amp; 1 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 \\\\ 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 \\\\ 1 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 \\\\ 0 &amp; 1 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 0 &amp; 0 \\\\ 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 0 \\\\ 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 \\\\ 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 1 &amp; 0 \\\\ 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 &amp; 1 \\end{bmatrix}\\)<\/span><\/p>\n<p>\u5e76\u4e14\u6ce8\u610f\u5230\uff0c\u5728\u6a21 \\(9\\) \u610f\u4e49\u4e0b\u76f8\u540c\u7684 \\(a_i\\) \u7684\u8f6c\u79fb\u77e9\u9635\u90fd\u662f\u76f8\u540c\u7684\uff0c\u6240\u4ee5\u53ef\u4ee5\u76f4\u63a5\u5f00\u4e00\u4e2a\u6876 \\(cnt\\) \u8868\u793a\u6b64\u6570\u91cf\uff0c\u5e76\u4e14\u8f6c\u79fb\u4f7f\u7528<strong>\u77e9\u9635\u5feb\u901f\u5e42<\/strong>\u5373\u53ef\u3002<\/p>\n<p>\u5faa\u73af\u77e9\u9635\u7684\u6bcf\u4e00\u884c\u90fd\u662f\u4e0a\u4e00\u884c\u5411\u5de6\/\u53f3\u79fb\u52a8\u4e00\u4f4d\u5f97\u5230\u7684\uff0c\u6240\u4ee5\u66b4\u529b\u4e58\u6cd5\u662f \\(O(9^2)\\) \u3002<\/p>\n<p>\u65f6\u95f4\u590d\u6742\u5ea6\uff1a \\(O\\left(n+9^3\\log \\sum\\limits_{i=1}^n b_i \\right)\\)<\/p>\n<p>&nbsp;<\/p>\n<pre class=\"lang:default decode:true \">#include &lt;cstdio&gt;\r\n#include &lt;cstdlib&gt;\r\n#include &lt;cstring&gt;\r\n#include &lt;climits&gt;\r\n\r\n#define MOD 1000000007\r\n#define _max(_a_,_b_) ((_a_)&gt;(_b_)?(_a_):(_b_))\r\n\r\ninline int getnum()\r\n{\r\n\tregister char c=0;\r\n\twhile(!(c&gt;='0' &amp;&amp; c&lt;='9'))\r\n\t\tc=getchar();\r\n\tregister int a=0;\r\n\twhile(c&gt;='0' &amp;&amp; c&lt;='9')\r\n\t\ta=a*10+c-'0',c=getchar();\r\n\treturn a;\r\n}\r\n\r\nstruct _mat\r\n{\r\n\tint a[9];\r\n\t_mat(){memset(a,0,sizeof(a));}\r\n\t_mat operator * (const _mat&amp;o)const\r\n\t{\r\n\t\t_mat ans;\r\n\t\tfor(register int i=0;i&lt;9;i++)\r\n\t\t\tfor(register int j=0;j&lt;9;j++)\r\n\t\t\t\t(ans.a[(i+j)%9]+=(long long)this-&gt;a[i]*o.a[j]%MOD)%=MOD;\r\n\t\treturn ans;\r\n\t}\r\n}I;\r\n\r\ninline _mat _pow(_mat base,register int b)\r\n{\r\n\t_mat ans=I;\r\n\twhile(b)\r\n\t{\r\n\t\tif(b&amp;1)\r\n\t\t\tans=ans*base;\r\n\t\tbase=base*base;\r\n\t\tb&gt;&gt;=1;\r\n\t}\r\n\treturn ans;\r\n}\r\n\r\nint a[105050],b[105050];\r\nint f[105050][15];\r\n\r\ninline void ComputeAns(int&amp;f,const int lf[],register int j,register int i)\r\n{\r\n\tregister int loop=(b[i]+1)\/9;\r\n\tif(loop)\r\n\t\tfor(register int k=0;k&lt;9;k++)\r\n\t\t\t(f+=(long long)lf[(j - k*a[i]%9 + 9) %9]*loop%MOD)%=MOD;\r\n\t\r\n\tregister int left=(b[i]+1)%9;\r\n\tfor(register int k=0;k&lt;left;k++)\r\n\t\t(f+=lf[(j - k*a[i]%9 + 9) %9])%=MOD;\r\n}\r\n\r\nint cnt[15];\r\n\r\nint main()\r\n{\r\n\tI.a[0]=1;\r\n\tregister int N=getnum();\r\n\tfor(register int i=1;i&lt;=N;i++)\r\n\t{\r\n\t\ta[i]=getnum()%9,b[i]=getnum();\r\n\t\tcnt[a[i]]+=b[i];\r\n\t}\r\n\t\r\n\t_mat ans=I,tmp;tmp.a[0]=1;\r\n\tfor(register int i=0;i&lt;9;i++)\r\n\t{\r\n\t\ttmp.a[i]++;\r\n\t\tans=ans*_pow(tmp,cnt[i]);\r\n\t\ttmp.a[i]--;\r\n\t}\r\n\t\r\n\tf[0][0]=1;\r\n\tfor(register int i=1;i&lt;=N;i++)\r\n\t\tfor(register int j=0;j&lt;9;j++)\r\n\t\t\tComputeAns(f[i][j],f[i-1],j,i);\r\n\tprintf(\"%d\\n%d\\n\",(ans.a[0]-1+MOD)%MOD,(f[N][0]-1+MOD)%MOD);\r\n\t\r\n\treturn 0;\r\n}<\/pre>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj200 &hellip; <a href=\"https:\/\/0.mnihyc.com\/blog\/archives\/1168\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">YZOJ P3033 \u80cc\u5305<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36,79,32,40,28],"tags":[],"class_list":["post-1168","post","type-post","status-publish","format-standard","hentry","category-harda","category-matrixfastpow","category-combmath","category-bagdp","category-countdp"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog<\/title>\n<meta name=\"description\" content=\"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 (n) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c (i) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a (a_i) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 (b_i) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog\" \/>\n<meta property=\"og:description\" content=\"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 (n) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c (i) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a (a_i) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 (b_i) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a\" \/>\n<meta property=\"og:url\" content=\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\" \/>\n<meta property=\"og:site_name\" content=\"mnihyc&#039;s Blog\" \/>\n<meta property=\"article:published_time\" content=\"2019-06-15T08:05:31+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-02-08T18:42:47+00:00\" \/>\n<meta name=\"author\" content=\"mnihyc\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@mnihyc\" \/>\n<meta name=\"twitter:site\" content=\"@mnihyc\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"mnihyc\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#article\",\"isPartOf\":{\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\"},\"author\":{\"name\":\"mnihyc\",\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\"},\"headline\":\"YZOJ P3033 \u80cc\u5305\",\"datePublished\":\"2019-06-15T08:05:31+00:00\",\"dateModified\":\"2020-02-08T18:42:47+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\"},\"wordCount\":211,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\"},\"articleSection\":[\"5.0 ~ 6.0\",\"\u77e9\u9635\u5feb\u901f\u5e42\",\"\u79bb\u6563\u6570\u5b66\",\"\u80cc\u5305\",\"\u8ba1\u6570DP\"],\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\",\"url\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\",\"name\":\"YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog\",\"isPartOf\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#website\"},\"datePublished\":\"2019-06-15T08:05:31+00:00\",\"dateModified\":\"2020-02-08T18:42:47+00:00\",\"description\":\"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 \\\\(n\\\\) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c \\\\(i\\\\) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a \\\\(a_i\\\\) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 \\\\(b_i\\\\) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a\",\"breadcrumb\":{\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/mnihyc.com\/blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"YZOJ P3033 \u80cc\u5305\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/mnihyc.com\/blog\/#website\",\"url\":\"https:\/\/mnihyc.com\/blog\/\",\"name\":\"mnihyc&#039;s Blog\",\"description\":\"Welcome!\",\"publisher\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/mnihyc.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"zh-Hans\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\",\"name\":\"mnihyc\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/8d111f863afc3f98816bc96220f97077d470a96f41088de9f19530fc480f8e72?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/8d111f863afc3f98816bc96220f97077d470a96f41088de9f19530fc480f8e72?s=96&d=mm&r=g\",\"caption\":\"mnihyc\"},\"logo\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog","description":"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 (n) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c (i) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a (a_i) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 (b_i) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168","og_locale":"zh_CN","og_type":"article","og_title":"YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog","og_description":"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 (n) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c (i) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a (a_i) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 (b_i) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a","og_url":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168","og_site_name":"mnihyc&#039;s Blog","article_published_time":"2019-06-15T08:05:31+00:00","article_modified_time":"2020-02-08T18:42:47+00:00","author":"mnihyc","twitter_card":"summary_large_image","twitter_creator":"@mnihyc","twitter_site":"@mnihyc","twitter_misc":{"\u4f5c\u8005":"mnihyc","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"3 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#article","isPartOf":{"@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168"},"author":{"name":"mnihyc","@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751"},"headline":"YZOJ P3033 \u80cc\u5305","datePublished":"2019-06-15T08:05:31+00:00","dateModified":"2020-02-08T18:42:47+00:00","mainEntityOfPage":{"@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168"},"wordCount":211,"commentCount":0,"publisher":{"@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751"},"articleSection":["5.0 ~ 6.0","\u77e9\u9635\u5feb\u901f\u5e42","\u79bb\u6563\u6570\u5b66","\u80cc\u5305","\u8ba1\u6570DP"],"inLanguage":"zh-Hans","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/0self.mnihyc.com\/blog\/archives\/1168#respond"]}]},{"@type":"WebPage","@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168","url":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168","name":"YZOJ P3033 \u80cc\u5305 - mnihyc&#039;s Blog","isPartOf":{"@id":"https:\/\/mnihyc.com\/blog\/#website"},"datePublished":"2019-06-15T08:05:31+00:00","dateModified":"2020-02-08T18:42:47+00:00","description":"YZOJ P3033 \u80cc\u5305 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u51fa\u9898\u4eba\uff1achj2001\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u5b58\u5728 \\(n\\) \u79cd\u7269\u54c1\uff0c\u5176\u4e2d\u7b2c \\(i\\) \u79cd\u7269\u54c1\u7684\u4ef7\u503c\u4e3a \\(a_i\\) \uff0c\u6700\u591a\u53ef\u4ee5\u7528 \\(b_i\\) \u4ef6\uff0c\u6c42\u4ece\u8fd9\u4e9b\u7269\u54c1\u4e2d\u9009\u53d6\u82e5\u5e72\u4ef6\uff08\u4e0d\u80fd\u4e3a","breadcrumb":{"@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/0self.mnihyc.com\/blog\/archives\/1168"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/0self.mnihyc.com\/blog\/archives\/1168#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/mnihyc.com\/blog"},{"@type":"ListItem","position":2,"name":"YZOJ P3033 \u80cc\u5305"}]},{"@type":"WebSite","@id":"https:\/\/mnihyc.com\/blog\/#website","url":"https:\/\/mnihyc.com\/blog\/","name":"mnihyc&#039;s Blog","description":"Welcome!","publisher":{"@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/mnihyc.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"zh-Hans"},{"@type":["Person","Organization"],"@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751","name":"mnihyc","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/8d111f863afc3f98816bc96220f97077d470a96f41088de9f19530fc480f8e72?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/8d111f863afc3f98816bc96220f97077d470a96f41088de9f19530fc480f8e72?s=96&d=mm&r=g","caption":"mnihyc"},"logo":{"@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/posts\/1168","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/comments?post=1168"}],"version-history":[{"count":0,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/posts\/1168\/revisions"}],"wp:attachment":[{"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/media?parent=1168"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/categories?post=1168"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/tags?post=1168"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}