{"trustable":false,"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":"\n\u003cfont color\u003d\"grey\"\u003e博弈玩腻了的小d想出了个新游戏和小b玩。\u003c/font\u003e\n\n\u003cp\u003e(这道题和下一题只有k的取值不同)\u003c/p\u003e\n\u003cp\u003e有一个无穷序列\"11212312341234512345612345671234567812345678912345678910...\",它是由\"1\",\"12\",\"123\",\"1234\"等连接而成的,这里只写出了前56位。小d问小b第k位是几。\u003c/p\u003e"}},{"title":"Input","value":{"format":"HTML","content":"第一行一个整数q( 1 \u0026le; q \u0026le; 500),是询问的个数。\n接下来q行每行一个整数k\u003csub\u003ei\u003c/sub\u003e( 1 \u0026le; k\u003csub\u003ei\u003c/sub\u003e \u0026le; 10\u003csup\u003e9\u003c/sup\u003e )表示要问第几位。"}},{"title":"Output","value":{"format":"HTML","content":"共q行,每行一个0~9的整数。"}},{"title":"Examples","value":{"format":"HTML","content":"\u003cdiv class\u003d\"sample-test\"\u003e\n \u003cdiv class\u003d\"input\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Input\n \u003c/div\u003e\n \u003cpre\u003e5\n1\n3\n20\n38\n56\n\u003c/pre\u003e\n \u003c/div\u003e\n \u003cdiv class\u003d\"output\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Output\n \u003c/div\u003e\n \u003cpre\u003e1\n2\n5\n2\n0\n\u003c/pre\u003e\n \u003c/div\u003e\n \u003cdiv class\u003d\"input\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Input\n \u003c/div\u003e\n \u003cpre\u003e4\n2132\n506\n999999999\n1000000000\n\u003c/pre\u003e\n \u003c/div\u003e\n \u003cdiv class\u003d\"output\"\u003e\n \u003cdiv class\u003d\"title\"\u003e\n Output\n \u003c/div\u003e\n \u003cpre\u003e8\n2\n9\n8\n\u003c/pre\u003e\n \u003c/div\u003e\n\u003c/div\u003e"}}]}