2 条题解

  • 0
    @ 2024-5-25 10:52:28

    确实挺难的,这是python的题解,仅供参考,请勿照抄!

    • 0
      @ 2024-5-25 10:51:34
      a=[int(i)for i in input().split()]
      b,c=[],[]
      for i in range(a[0]):
          b.append([int(i)for i in input().split()])
      for i in range(a[0]):
          c.append([int(i)for i in input().split()])
      ans=0
      for i in range(len(b)):
          for j in range(len(b[i])):
              if b[i][j]==c[i][j]:
                  ans+=1
      answer=0
      for i in range(len(b)):
          for j in range(len(b[i])):
              answer+=1
      answer=ans/answer*100
      answer="%.2f"%answer
      print(answer)
      
      • 1

      信息

      ID
      257
      时间
      1000ms
      内存
      128MiB
      难度
      10
      标签
      递交数
      9
      已通过
      3
      上传者