{"trustable":true,"sections":[{"title":"","value":{"format":"HTML","content":"\u003cstyle type\u003d\"text/css\"\u003e pre { text-align:left; font-family: \"Courier New\", Courier, monospace; font-size: 16px; white-space: pre; line-height:20px; text-indent: 0px; }\u003c/style\u003e\u003cdiv class\u003d\"pro_desc\"\u003e\n \u003cp\u003eGiven A,B,C, You should quickly calculate the result of A^B mod C. (1\u0026lt;\u003dA,C\u0026lt;\u003d1000000000,1\u0026lt;\u003dB\u0026lt;\u003d10^1000000).\u003c/p\u003e \n\u003c/div\u003e"}},{"title":"Input","value":{"format":"HTML","content":"\u003cdiv class\u003d\"pro_desc\"\u003e\n There are multiply testcases. Each testcase, there is one line contains three integers A, B and C, separated by a single space.\n \u003cp\u003e\u003c/p\u003e \n\u003c/div\u003e"}},{"title":"Output","value":{"format":"HTML","content":"\u003cdiv class\u003d\"pro_desc\"\u003e\n For each testcase, output an integer, denotes the result of A^B mod C.\n \u003cp\u003e\u003c/p\u003e \n\u003c/div\u003e"}},{"title":"Sample Input","value":{"format":"HTML","content":"\u003cpre\u003e3 2 4\r\n2 10 1000\r\n\u003c/pre\u003e"}},{"title":"Sample Output","value":{"format":"HTML","content":"\u003cpre\u003e1\r\n24\r\n\u003c/pre\u003e"}}]}