Run ID:79753
提交时间:2024-07-09 22:47:39
def a(b, c): d = 0 e = len(b) * len(b[0]) for i in range(len(b)): for j in range(len(b[0])): if b[i][j] == c[i][j]: d += 1 x = (d/ e) * 100 return round(x, 2) def main(): m, n = map(int, input().split()) b = [list(map(int, input().split())) for _ in range(m)] c = [list(map(int, input().split())) for _ in range(m)] x = a(b, c) print(x) if __name__ == "__main__": main()