{"id":1172,"date":"2019-06-15T16:44:00","date_gmt":"2019-06-15T08:44:00","guid":{"rendered":"https:\/\/0.mnihyc.com\/blog\/?p=1172"},"modified":"2020-04-22T11:39:32","modified_gmt":"2020-04-22T03:39:32","slug":"yzoj-p3527-fjoi2018d1t3%e5%9f%8e%e5%b8%82%e8%b7%af%e5%be%84%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"https:\/\/0.mnihyc.com\/blog\/archives\/1172","title":{"rendered":"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898"},"content":{"rendered":"<h1 style=\"text-align: center;\">YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898<\/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;\">\u96be\u5ea6\uff1a<span style=\"color: #ff6600;\">\\(6.5\\)<\/span><\/p>\n<ul>\n<li>\n<h3><strong>\u9898\u76ee\u63cf\u8ff0<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u7ed9\u51fa\u4e00\u5f20 \\(n\\) \u4e2a\u70b9\u7684\u6709\u5411\u56fe \\(G(V, E)\\) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 \\(u, v\\) \uff08\\(u\\) \u53ef\u4ee5\u7b49\u4e8e \\(v\\) \uff09\uff0c\\(u\\) \u5411 \\(v\\) \u7684\u8fde\u8fb9\u6570\u4e3a\uff1a\\(\\sum\\limits_{i=1}^k {out[u, i] \\times in[v, i]}\\) \u3002<\/p>\n<p>\u7ed9\u5b9a \\(k\\) \u548c\u6570\u7ec4 \\(out, in\\) \uff0c\u73b0\u5728\u6709 \\(m\\) \u4e2a\u8be2\u95ee\uff0c\u6bcf\u6b21\u8be2\u95ee\u7ed9\u51fa\u4e09\u4e2a\u53c2\u6570 \\(u, v, d\\)\uff0c\u4f60\u9700\u8981\u56de\u7b54\u4ece\u8282\u70b9 \\(u\\) \u51fa\u53d1\uff0c\u7ecf\u8fc7<strong>\u4e0d\u8d85\u8fc7 \\(d\\) \u6761<\/strong>\u8fb9\u5230\u8fbe\u8282\u70b9 \\(v\\) \u7684\u8def\u5f84\u6709\u591a\u5c11\u79cd\u3002<\/p>\n<p>\u7b54\u6848\u5bf9 \\(10^9+7\\) \u53d6\u6a21\u3002<\/p>\n<ul>\n<li>\n<h3><strong>\u8f93\u5165\u683c\u5f0f<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u7b2c\u4e00\u884c\u4e24\u4e2a\u6574\u6570 \\(n, k\\) \u3002<\/p>\n<p>\u63a5\u4e0b\u6765 \\(n\\) \u884c\uff0c\u7b2c \\(i\\) \u884c\u6709 \\(2k\\) \u4e2a\u6574\u6570\uff0c\u524d \\(k\\) \u4e2a\u6574\u6570\u63cf\u8ff0 \\(out[i][]\\)\uff0c\u540e \\(k\\) \u4e2a\u6570\u63cf\u8ff0 \\(in[i][]\\) \u3002<\/p>\n<p>\u63a5\u4e0b\u6765\u4e00\u884c\u4e00\u4e2a\u6574\u6570 \\(m\\) \u3002<\/p>\n<p>\u63a5\u4e0b\u6765 \\(m\\) \u884c\uff0c\u6bcf\u884c\u4e09\u4e2a\u6574\u6570 \\(u, v, d\\)\uff0c\u63cf\u8ff0\u4e00\u7ec4\u8be2\u95ee\u3002<\/p>\n<ul>\n<li>\n<h3><strong>\u8f93\u51fa\u683c\u5f0f<\/strong><\/h3>\n<\/li>\n<\/ul>\n<p>\u5bf9\u4e8e\u6bcf\u4e2a\u8be2\u95ee\uff0c\u8f93\u51fa\u4e00\u4e2a\u65b9\u6848\u6570\u3002\u7531\u4e8e\u7b54\u6848\u53ef\u80fd\u592a\u5927\uff0c\u8f93\u51fa\u5176\u9664\u4ee5 \\(10^9+7\\) \u540e\u7684\u4f59\u6570\u3002<\/p>\n<p><!--more--><\/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 \">5 2 \r\n2 5 4 3\r\n7 9 2 4\r\n0 1 5 2\r\n6 3 9 2\r\n2147483647 1000000001 233522 788488\r\n10\r\n1 1 0\r\n2 2 1\r\n2 4 5\r\n4 3 10\r\n3 4 50\r\n1 5 1000\r\n3 5 1000000000\r\n1 2 500000000\r\n4 5 2147483647\r\n3 1 2147483647\r\n<\/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 \">1\r\n51\r\n170107227\r\n271772358\r\n34562176\r\n890241289\r\n8516097\r\n383966304\r\n432287042\r\n326522835\r\n<\/pre>\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 \\leq 50 ,k \\leq 20, m \\leq 45\\) \u3002<\/p>\n<p>\u5bf9\u4e8e \\(90\\%\\) \u7684\u6570\u636e\uff0c\\(n \\leq 1000, k \\leq 20, m \\leq 50\\) \u3002<\/p>\n<p>\u5bf9\u4e8e\u53e6\u5916 \\(10\\%\\) \u7684\u6570\u636e\uff0c\\(n \\leq 1000, k=1, m \\leq 100\\) \u3002<\/p>\n<p>\u6240\u6709\u8f93\u5165\u6570\u636e\u4e0d\u8d85\u8fc7 <span class=\"lang:default decode:true  crayon-inline \">int<\/span>\u00a0 \u8303\u56f4\u3002<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Source: BZOJ 3583\u00a0 <del>\uff08\u4e0d\u662f FJOI \u5417\uff1fwww<\/del><\/p>\n<p><!--more--><\/p>\n<hr \/>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>\u9996\u5148\uff0c\u82e5\u77e9\u9635 \\(A\\) \u4e2d \\((s, t)\\) \u7684\u503c\u8868\u793a\u4ece \\(s\\) \u5230 \\(t\\) \u7684\u8def\u5f84\u6761\u6570\uff0c\u90a3\u4e48 \\(A^d\\) \u8868\u793a\u4ece \\(s\\) \u51fa\u53d1<strong>\u521a\u597d\u7ecf\u8fc7 \\(d\\) \u6761<\/strong>\u8def\u5230\u8fbe \\(t\\) \u7684\u65b9\u6848\u6570\u3002<\/p>\n<p>\u53ef\u4ee5\u8003\u8651\u77e9\u9635\u4e58\u6cd5\u7684\u8fc7\u7a0b\uff0c\\((i, j) = (i, k) \\times (k, j)\\) \uff0c\u5176\u5b9e\u5c31\u662f\u679a\u4e3e\u7ecf\u8fc7\u70b9 \\(k\\) \u628a\u65b9\u6848\u6570\u4e58\u8d77\u6765\uff0c\u663e\u7136\u53ef\u4ee5\u5f97\u5230\u8fd9\u4e2a\u7ed3\u8bba\u3002<\/p>\n<p>\u90a3\u4e48\u9898\u76ee\u8bf4\u7684 <strong>\u201c\u4e0d\u8d85\u8fc7 \\(d\\) \u6761\u201d<\/strong> \u7684\u610f\u601d\u5c31\u662f \\(A^0+A^1+A^2+ \\cdots + A^d\\) \uff0c\u66b4\u529b\u7b97\u4e00\u4e0b\u5c31\u4f1a\u6709 \\(40pts\\) \u3002<\/p>\n<p>\\(s \\to t\\) \u7684\u8def\u5f84\u6761\u6570\u4e3a \\(\\sum\\limits_{i=1}^k {out[s, i] \\times in[t, i]}\\) \uff0c\u4e5f\u53ef\u4ee5\u770b\u6210\u662f\u4e00\u4e2a\u77e9\u9635\u4e58\u6cd5\u7684\u8fc7\u7a0b\uff0c\u5373 \\(OI^T\\) \u3002<\/p>\n<p>\u90a3\u4e48\u8981\u6c42\u7684\u662f <span style=\"font-size: 16px;\">\\(G^d=\\left(OI^T\\right)^d\\)<\/span> \uff0c\u82e5\u4f7f\u7528<strong>\u77e9\u9635\u5feb\u901f\u5e42<\/strong>\u7684\u8bdd\u65f6\u95f4\u590d\u6742\u5ea6\u4e3a \\(O(n^2k \\log d)\\)\uff0c\u56e0\u4e3a\u8ba1\u7b97\u4e00\u6b21 \\(OI^T\\) \uff08\\(O\\) \u4e3a \\(n \\times k\\)\uff0c\\(I^T\\) \u4e3a \\(k \\times n\\)\uff09\u9700\u8981 \\(O(n^2k)\\) \u7684\u590d\u6742\u5ea6\uff0c\u5f88\u660e\u663e\u65e0\u6cd5\u901a\u8fc7\u672c\u9898<del>\uff08\u6bd5\u7adf\u662f FJOI \u7684\u673a\u5b50\uff09<\/del>\u3002<\/p>\n<p>\u8003\u8651\u4f18\u5316\uff0c\u6839\u636e\u77e9\u9635\u4e58\u6cd5\u7684<strong>\u7ed3\u5408\u5f8b<\/strong>\uff0c\u6709<\/p>\n<p><span style=\"font-size: 16px;\">\\(G^d=\\left(OI^T\\right)^d = \\underbrace{OI^T \\times OI^T \\times \\cdots \\times OI^T}_d \\\\ =O \\times \\underbrace{I^TO \\times I^TO \\times \\cdots \\times I^TO}_{d-1} \\times I^T = O\\left(I^TO\\right)^{d-1}I^T\\)<\/span><\/p>\n<p>\u56e0\u4e3a \\(I^T\\) \u4e3a \\(k \\times n\\)\uff0c\\(O\\) \u4e3a \\(n \\times k\\)\uff0c\u6240\u4ee5\u8ba1\u7b97\u4e00\u6b21 \\(I^TO\\) \u7684\u590d\u6742\u5ea6\u53ea\u662f \\(O(nk^2)\\)\uff0c\u800c\u672c\u9898\u4e2d \\(k\\) \u5f88\u5c0f\uff0c\u53ef\u4ee5\u63a5\u53d7\u3002<\/p>\n<p>\u53e6\u5916\uff0c\u77e9\u9635\u5e42\u548c\u6ca1\u6709\u4ec0\u4e48 \\(A^0+A^1+\\cdots+A^d = \\frac{A^{d+1}-1}{x-1}\\) \uff08\u4e0d\u53ef\u80fd\u6709\u597d\u5427www\uff09\uff0c\u8981\u60f3\u8fbe\u5230\u4e0e\u5feb\u901f\u5e42\u540c\u9636\u7684\u590d\u6742\u5ea6\uff0c\u9700\u8981\u901a\u8fc7\u522b\u7684\u65b9\u6cd5\u8ba1\u7b97\u3002<\/p>\n<p>\u6ce8\u610f\u5230<\/p>\n<p><span style=\"font-size: 16px;\">\\(A^0+A^1+A^2+ \\cdots A^{2n} = \\left(A^0+A^1+\\cdots+A^n\\right) + A^n \\left(A^0+A^1+\\cdots+A^n\\right)\\)<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\\(A^0+A^1+A^2+ \\cdots A^{2n+1} = \\left(A^0+A^1+\\cdots+A^n\\right) + A^n \\left(A^0+A^1+\\cdots+A^n+A^{n+1}\\right)\\)<\/span><\/p>\n<p>\u6240\u4ee5\u53ef\u4ee5\u901a\u8fc7<strong>\u5206\u6cbb\u6cd5<\/strong>\u5728 \\(O(\\log d)\\) \u7684\u590d\u6742\u5ea6\u5185\u5b8c\u6210\u3002<\/p>\n<p>\u6700\u540e\u518d\u5bf9\u4e8e\u6bcf\u4e2a\u8be2\u95ee\u7684 \\(s, t\\) \u4e58\u4e00\u904d\u5373\u53ef\uff0c\u65f6\u95f4\u590d\u6742\u5ea6 \\(O\\left(nk^2+mk^3\\log d\\right)\\) \u3002<\/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\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\nint pK;\r\nstruct _mat\r\n{\r\n\tint a[20][20];\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;pK;i++)\r\n\t\t\tfor(register int j=0;j&lt;pK;j++)\r\n\t\t\t\tfor(register int k=0;k&lt;pK;k++)\r\n\t\t\t\t\t(ans.a[i][j]+=(long long)this-&gt;a[i][k]*o.a[k][j]%MOD)%=MOD;\r\n\t\treturn ans;\r\n\t}\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;pK;i++)\r\n\t\t\tfor(register int j=0;j&lt;pK;j++)\r\n\t\t\t\tans.a[i][j]=(this-&gt;a[i][j]+o.a[i][j])%MOD;\r\n\t\treturn ans;\r\n\t}\r\n}I;\r\n\r\nint vin[1050][20],vout[1050][20];\r\n_mat base;\r\n\r\nvoid PowerSum(_mat&amp;A,_mat&amp;B,register int d)\r\n{\r\n\tif(d==1)\r\n\t{\r\n\t\tA=B=base;\r\n\t\treturn;\r\n\t}\r\n\tPowerSum(A,B,d&gt;&gt;1);\r\n\tB=B+B*A,A=A*A;\r\n\tif(d&amp;1)\r\n\t\tA=base*A,B=B+A;\r\n}\r\n\r\nint main()\r\n{\r\n\tregister int N=getnum(),K=getnum();\r\n\tpK=K;\r\n\tfor(register int i=0;i&lt;K;i++)\r\n\t\tI.a[i][i]=1;\r\n\tfor(register int i=0;i&lt;N;i++)\r\n\t{\r\n\t\tfor(register int j=0;j&lt;K;j++)\r\n\t\t\tvout[i][j]=getnum()%MOD;\r\n\t\tfor(register int j=0;j&lt;K;j++)\r\n\t\t\tvin[i][j]=getnum()%MOD;\r\n\t}\r\n\tfor(register int i=0;i&lt;K;i++)\r\n\t\tfor(register int j=0;j&lt;K;j++)\r\n\t\t\tfor(register int k=0;k&lt;N;k++)\r\n\t\t\t\t(base.a[i][j]+=(long long)vin[k][i]*vout[k][j]%MOD)%=MOD;\r\n\t\r\n\tregister int M=getnum();\r\n\tfor(register int lp=1;lp&lt;=M;lp++)\r\n\t{\r\n\t\tregister int u=getnum()-1,v=getnum()-1,d=getnum();\r\n\t\tregister int ans=(u==v);\r\n\t\tif(!d)\r\n\t\t{\r\n\t\t\tprintf(\"%d\\n\",ans);\r\n\t\t\tcontinue;\r\n\t\t}\r\n\t\t\r\n\t\t_mat ansum,ad;\r\n\t\tif(d&gt;1)\r\n\t\t\tPowerSum(ad,ansum,d-1);\r\n\t\tansum=ansum+I;\r\n\t\tfor(register int j=0;j&lt;K;j++)\r\n\t\t\tfor(register int k=0;k&lt;K;k++)\r\n\t\t\t\t(ans+=(long long)vout[u][j]*ansum.a[j][k]%MOD*vin[v][k]%MOD)%=MOD;\r\n\t\tprintf(\"%d\\n\",ans);\r\n\t}\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 P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a1 &hellip; <a href=\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898<\/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":[41,38,79,32,51],"tags":[],"class_list":["post-1172","post","type-post","status-publish","format-standard","hentry","category-proa","category-partition","category-matrixfastpow","category-combmath","category-linearalgebra"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog<\/title>\n<meta name=\"description\" content=\"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 (n) \u4e2a\u70b9\u7684\u6709\u5411\u56fe (G(V, E)) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 (u, v) \uff08(u) \u53ef\u4ee5\u7b49\u4e8e (v) \uff09\uff0c(u) \u5411 (v)\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog\" \/>\n<meta property=\"og:description\" content=\"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 (n) \u4e2a\u70b9\u7684\u6709\u5411\u56fe (G(V, E)) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 (u, v) \uff08(u) \u53ef\u4ee5\u7b49\u4e8e (v) \uff09\uff0c(u) \u5411 (v)\" \/>\n<meta property=\"og:url\" content=\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\" \/>\n<meta property=\"og:site_name\" content=\"mnihyc&#039;s Blog\" \/>\n<meta property=\"article:published_time\" content=\"2019-06-15T08:44:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-04-22T03:39:32+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:\/\/0.mnihyc.com\/blog\/archives\/1172#article\",\"isPartOf\":{\"@id\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\"},\"author\":{\"name\":\"mnihyc\",\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\"},\"headline\":\"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898\",\"datePublished\":\"2019-06-15T08:44:00+00:00\",\"dateModified\":\"2020-04-22T03:39:32+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\"},\"wordCount\":288,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751\"},\"articleSection\":[\"6.0 ~ 7.0\",\"\u5206\u6cbb\",\"\u77e9\u9635\u5feb\u901f\u5e42\",\"\u79bb\u6563\u6570\u5b66\",\"\u7ebf\u6027\u4ee3\u6570\"],\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/0.mnihyc.com\/blog\/archives\/1172#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\",\"url\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\",\"name\":\"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog\",\"isPartOf\":{\"@id\":\"https:\/\/mnihyc.com\/blog\/#website\"},\"datePublished\":\"2019-06-15T08:44:00+00:00\",\"dateModified\":\"2020-04-22T03:39:32+00:00\",\"description\":\"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 \\\\(n\\\\) \u4e2a\u70b9\u7684\u6709\u5411\u56fe \\\\(G(V, E)\\\\) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 \\\\(u, v\\\\) \uff08\\\\(u\\\\) \u53ef\u4ee5\u7b49\u4e8e \\\\(v\\\\) \uff09\uff0c\\\\(u\\\\) \u5411 \\\\(v\\\\)\",\"breadcrumb\":{\"@id\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/0.mnihyc.com\/blog\/archives\/1172\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/0.mnihyc.com\/blog\/archives\/1172#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/mnihyc.com\/blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898\"}]},{\"@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 P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog","description":"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 (n) \u4e2a\u70b9\u7684\u6709\u5411\u56fe (G(V, E)) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 (u, v) \uff08(u) \u53ef\u4ee5\u7b49\u4e8e (v) \uff09\uff0c(u) \u5411 (v)","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:\/\/0.mnihyc.com\/blog\/archives\/1172","og_locale":"zh_CN","og_type":"article","og_title":"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog","og_description":"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 (n) \u4e2a\u70b9\u7684\u6709\u5411\u56fe (G(V, E)) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 (u, v) \uff08(u) \u53ef\u4ee5\u7b49\u4e8e (v) \uff09\uff0c(u) \u5411 (v)","og_url":"https:\/\/0.mnihyc.com\/blog\/archives\/1172","og_site_name":"mnihyc&#039;s Blog","article_published_time":"2019-06-15T08:44:00+00:00","article_modified_time":"2020-04-22T03:39:32+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:\/\/0.mnihyc.com\/blog\/archives\/1172#article","isPartOf":{"@id":"https:\/\/0.mnihyc.com\/blog\/archives\/1172"},"author":{"name":"mnihyc","@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751"},"headline":"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898","datePublished":"2019-06-15T08:44:00+00:00","dateModified":"2020-04-22T03:39:32+00:00","mainEntityOfPage":{"@id":"https:\/\/0.mnihyc.com\/blog\/archives\/1172"},"wordCount":288,"commentCount":0,"publisher":{"@id":"https:\/\/mnihyc.com\/blog\/#\/schema\/person\/61e167d6d591fdd20dcfee2cf848a751"},"articleSection":["6.0 ~ 7.0","\u5206\u6cbb","\u77e9\u9635\u5feb\u901f\u5e42","\u79bb\u6563\u6570\u5b66","\u7ebf\u6027\u4ee3\u6570"],"inLanguage":"zh-Hans","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/0.mnihyc.com\/blog\/archives\/1172#respond"]}]},{"@type":"WebPage","@id":"https:\/\/0.mnihyc.com\/blog\/archives\/1172","url":"https:\/\/0.mnihyc.com\/blog\/archives\/1172","name":"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898 - mnihyc&#039;s Blog","isPartOf":{"@id":"https:\/\/mnihyc.com\/blog\/#website"},"datePublished":"2019-06-15T08:44:00+00:00","dateModified":"2020-04-22T03:39:32+00:00","description":"YZOJ P3527 \u57ce\u5e02\u8def\u5f84\u95ee\u9898 \u65f6\u95f4\u9650\u5236\uff1a1000MS \u00a0\u00a0\u00a0\u00a0 \u5185\u5b58\u9650\u5236\uff1a131072KB \u96be\u5ea6\uff1a \u9898\u76ee\u63cf\u8ff0 \u7ed9\u51fa\u4e00\u5f20 \\(n\\) \u4e2a\u70b9\u7684\u6709\u5411\u56fe \\(G(V, E)\\) \u3002\u5bf9\u4e8e\u4efb\u610f\u4e24\u4e2a\u70b9 \\(u, v\\) \uff08\\(u\\) \u53ef\u4ee5\u7b49\u4e8e \\(v\\) \uff09\uff0c\\(u\\) \u5411 \\(v\\)","breadcrumb":{"@id":"https:\/\/0.mnihyc.com\/blog\/archives\/1172#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/0.mnihyc.com\/blog\/archives\/1172"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/0.mnihyc.com\/blog\/archives\/1172#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/mnihyc.com\/blog"},{"@type":"ListItem","position":2,"name":"YZOJ P3527 [FJOI2018D1T3]\u57ce\u5e02\u8def\u5f84\u95ee\u9898"}]},{"@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\/1172","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=1172"}],"version-history":[{"count":0,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/posts\/1172\/revisions"}],"wp:attachment":[{"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/media?parent=1172"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/categories?post=1172"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/0.mnihyc.com\/blog\/wp-json\/wp\/v2\/tags?post=1172"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}