{"trustable":true,"prependHtml":"\u003cstyle type\u003d\u0027text/css\u0027\u003e\n .input, .output {\n border: 1px solid #888888;\n }\n .output {\n margin-bottom: 1em;\n position: relative;\n top: -1px;\n }\n .output pre, .input pre {\n background-color: #EFEFEF;\n line-height: 1.25em;\n margin: 0;\n padding: 0.25em;\n }\n \u003c/style\u003e\n \u003clink rel\u003d\"stylesheet\" href\u003d\"//codeforces.org/s/96598/css/problem-statement.css\" type\u003d\"text/css\" /\u003e\n\u003cscript\u003e\n window.katexOptions \u003d {\n delimiters: [\n {left: \u0027$$$$$$\u0027, right: \u0027$$$$$$\u0027, display: true},\n {left: \u0027$$$\u0027, right: \u0027$$$\u0027, display: false},\n {left: \u0027$$\u0027, right: \u0027$$\u0027, display: true},\n {left: \u0027$\u0027, right: \u0027$\u0027, display: false}\n ]\n };\n\u003c/script\u003e\n","sections":[{"title":"","value":{"format":"HTML","content":"\u003cp\u003eYukikaze正在学习数论。她想知道是否可以将介于$$$1$$$和$$$n$$$之间的所有正整数排成几个不相交的循环,使得每个循环包含至少三个整数,并且任何循环中相邻两个整数的和都是素数。\u003c/p\u003e\u003cp\u003e素数是大于$$$1$$$且除了自身和$$$1$$$外不能被任何正整数整除的整数。\u003c/p\u003e\u003cp\u003e具体来说,Yukikaze想要找到$$$k$$$个序列$$$A_1, A_2, \\ldots, A_k$$$,满足以下条件:\u003c/p\u003e\u003col\u003e \u003cli\u003e 每个序列至少包含三个整数。 \u003c/li\u003e\u003cli\u003e $$$1$$$和$$$n$$$之间的每个整数只出现在一个序列中。 \u003c/li\u003e\u003cli\u003e 对于任意序列$$$A_i \u003d \\{ a_{i,1}, a_{i,2}, \\ldots, a_{i,l} \\}$$$,任何$$$1 \\leq j \u0026lt; l$$$都是素数,且$$$a_{i,1}+a_{i,l}$$$也必须是素数。 \u003c/li\u003e\u003c/ol\u003e"}},{"title":"输入","value":{"format":"HTML","content":"\u003cp\u003e输入仅包含一个正偶数$$$n$$$($$$2 \\leq n \\leq 10^4$$$)。\u003c/p\u003e"}},{"title":"输出","value":{"format":"HTML","content":"\u003cp\u003e在第一行输出循环的数量$$$k$$$。\u003c/p\u003e\u003cp\u003e接下来的$$$k$$$行中,每行以一个正整数$$$l$$$开头,表示循环中的整数数量,然后是按顺序排列的循环中的整数。如果有多个答案,可以输出任意一个。每行末尾不要打印任何额外的空格。\u003c/p\u003e\u003cp\u003e如果无法排列这$$$n$$$个整数,以单行输出$$$-1$$$。\u003c/p\u003e"}},{"title":"示例","value":{"format":"HTML","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003e8\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003e1\n8 1 2 3 8 5 6 7 4\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e"}},{"title":"","value":{"format":"HTML","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003e18\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003e3\n4 1 2 3 4\n6 5 6 7 10 9 8\n8 11 12 17 14 15 16 13 18\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e"}}]}