Sum and Prod

  • + 0 comments

    we don't need to give axis=0 for numpy.prod() here's my solution: import numpy n,m=input().split() arr=numpy.array([input().split()for _ in range(int(n))],int) print(numpy.prod(numpy.sum(arr,axis=0)))