Collections.namedtuple()

  • + 0 comments

    from collections import namedtuple

    n, columns = int(input()), input().split(); Student = namedtuple('Student', columns)

    print(f"{sum(float(Student(*input().split()).MARKS) for _ in range(n)) / n:.2f}")