{"trustable":false,"sections":[{"title":"","value":{"format":"MD","content":"多组数据(超过一百组),输入直到文件尾。\n\n每组数据给定 n * n 的三个矩阵 A,B 和 C,问是否满足 $A * B \u003d C$。\n\n$n \u003c\u003d 500,\\ -100 \u003c\u003d A_{i,j},B_{i,j} \u003c\u003d 100,\\ -10^9 \u003c\u003d C_{i,j} \u003c\u003d10^9$。\n\n---\n\n\u003cp\u003eYou are given three \u003ci\u003en\u003c/i\u003e × \u003ci\u003en\u003c/i\u003e matrices \u003ci\u003eA\u003c/i\u003e, \u003ci\u003eB\u003c/i\u003e and \u003ci\u003eC\u003c/i\u003e. Does the equation \u003ci\u003eA\u003c/i\u003e × \u003ci\u003eB\u003c/i\u003e \u003d \u003ci\u003eC\u003c/i\u003e hold true?\u003c/p\u003e"}},{"title":"Input","value":{"format":"MD","content":"\u003cp\u003eThe first line of input contains a positive integer \u003ci\u003en\u003c/i\u003e (\u003ci\u003en\u003c/i\u003e ≤ 500) followed by the the three matrices \u003ci\u003eA\u003c/i\u003e, \u003ci\u003eB\u003c/i\u003e and \u003ci\u003eC \u003c/i\u003erespectively. Each matrix\u0027s description is a block of n × n integers.\u003c/p\u003e\u003cp\u003eIt guarantees that the elements of \u003ci\u003eA\u003c/i\u003e and \u003ci\u003eB\u003c/i\u003e are less than 100 in absolute value and elements of \u003ci\u003eC\u003c/i\u003e are less than 10,000,000 in absolute value.\u003c/p\u003e"}},{"title":"Output","value":{"format":"MD","content":"\u003cp\u003eOutput \"YES\" if the equation holds true, otherwise \"NO\".\u003c/p\u003e"}},{"title":"Sample","value":{"format":"MD","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\u003e2\n1 0\n2 3\n5 1\n0 8\n5 1\n10 26\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003eYES\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}},{"title":"Hint","value":{"format":"MD","content":"Multiple inputs will be tested. So O(n\u003csup\u003e3\u003c/sup\u003e) algorithm will get TLE."}}]}