{"trustable":true,"sections":[{"title":"","value":{"format":"MD","content":"Find the result of the following code:\n\n\u003cdiv class\u003d\"haveborder\"\u003e\n\t\n``` \nlong long pairsFormLCM( int n ) {\n long long res \u003d 0;\n for( int i \u003d 1; i \u003c\u003d n; i++ )\n for( int j \u003d i; j \u003c\u003d n; j++ )\n if( lcm(i, j) \u003d\u003d n ) res++; // lcm means least common multiple\n return res;\n}\n```\n\t\n\u003c/div\u003e\n\nA straight forward implementation of the code may time out. If you analyze the code, you will find that the code actually counts the number of pairs **(i, j)** for which **lcm(i, j) \u003d n** and **(i \u0026#8804; j)**."}},{"title":"Input","value":{"format":"MD","content":"Input starts with an integer **T (\u0026#8804; 200)**, denoting the number of test cases.\n\nEach case starts with a line containing an integer **n (1 \u0026#8804; n \u0026#8804; 10\u003csup\u003e14\u003c/sup\u003e)**."}},{"title":"Output","value":{"format":"MD","content":"For each case, print the case number and the value returned by the function **pairsFormLCM(n)**."}},{"title":"Sample","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\u003e15\n2\n3\n4\n6\n8\n10\n12\n15\n18\n20\n21\n24\n25\n27\n29\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003eCase 1: 2\nCase 2: 2\nCase 3: 3\nCase 4: 5\nCase 5: 4\nCase 6: 5\nCase 7: 8\nCase 8: 5\nCase 9: 8\nCase 10: 8\nCase 11: 5\nCase 12: 11\nCase 13: 3\nCase 14: 4\nCase 15: 2\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}