scientific_comp_projects/CODE/[python]kattis/trivial/grass_seed_inc.py
2021-10-29 15:16:40 +02:00

11 lines
209 B
Python

cost = float(input())
nb_lawns = int(input())
total = 0
for i in range(nb_lawns):
line = input()
width, length = line.split(' ')
total = float(width)* float(length)*cost + total
print(total)