u, b, h = map(int, input().split(",")) Ans = (u+b) * h / 2 print(f'{Ans:.2f}')