Problem:
 Score : 100 points    Problem Statement You are given a trapezoid. The lengths of its upper base, lower base, and height are a , b , and h , respectively.    An example of a trapezoid   Find the area of this trapezoid.      Constraints  1≦a≦100  1≦b≦100  1≦h≦100  All input values are integers.  h is even.         Input The input is given from Standard Input in the following format:  a  b  h       Output Print the area of the given trapezoid. It is guaranteed that the area is an integer.        Sample Input 1 3
4
2      Sample Output 1 7  When the lengths of the upper base, lower base, and height are 3 , 4 , and 2 , respectively, the area of the trapezoid is (3+4)×2/2 = 7 .       Sample Input 2 4
4
4      Sample Output 2 16  In this case, a parallelogram is given, which is also a trapezoid.

Solution (Python):
import sys
import math
import bisect
 
def main():
    a = int(input())
    b = int(input())
    h = int(input())
    print((a + b) * h // 2)
 
if __name__ == "__main__":
    main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
ue = int(input())
sita = int(input())
takasa = int(input())
men = (ue+sita)*takasa/2
print(int(men))

Solution (Python):

a, b, h = map(int, open(0))


print((a + b) * h >> 1)

Solution (Python):
import sys
input = sys.stdin.readline

inputs = [int(input()) for i in range(3)]

ans = ((int(inputs[0]) + int(inputs[1]))*int(inputs[2]))/2

print(int(ans))

Solution (Python):
def q1():
    a = int(input())
    b = int(input())
    h = int(input())
    ans = (a+b)*h//2
    return ans


if __name__ == '__main__':
    print(q1())

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(int((a + b) * h / 2))

Solution (Python):
a=int(input())
b=int(input())
c=int(input())
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
A=(a+b)/2*h
print(int(A))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = (a + b) * h / 2
print(int(S))

Solution (Python):
a= int(input())
b= int(input())
h= int(input())
print((a+b)*h//2)

Solution (Python):
print((int(input()) + int(input())) * int(input()) // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(((a+b)*h)//2)

Solution (Python):
a=[int(input()) for i in range(3)]
print(int((a[0]+a[1])*a[2]/2))

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
ans = (a + b) * h / 2

print(int(ans))

Solution (Python):
def main():
    a = int(input())
    b = int(input())
    h = int(input())

    print((a + b) * h // 2)


if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a, b, h = int(input()), int(input()), int(input())
print(int((a+b)/2 * h))

Solution (Python):
A = int(input())
B = int(input())
H = int(input())
print((A+B)*H//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
import sys
input = sys.stdin.readline


def readstr():
    return input().strip()


def readint():
    return int(input())


def readnums():
    return map(int, input().split())


def readstrs():
    return input().split()


def main():
    a = readint()
    b = readint()
    h = readint()
    print((a + b) * h // 2)


if __name__ == "__main__":
    main()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a= int(input())
b= int(input())
h= int(input())
eq= (a+b)*h/2
print(int(eq))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
ans = (a + b) * h // 2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(((a+b) * h) // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
def solve():
    ans = (a+b)*h//2
    return ans
print(solve())

Solution (Python):
from collections import Counter,defaultdict,deque
from heapq import heappop,heappush,heapify
import sys,bisect,math,itertools,fractions,pprint
sys.setrecursionlimit(10**8)
mod = 10**9+7
INF = float('inf')
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))

a = inp()
b = inp()
c = inp()
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
def resolve():
  a = int(input())
  b = int(input())
  h = int(input())
  print((a+b) * h // 2)
  return

if __name__ == "__main__":
  resolve()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(h*(a+b)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b)*h//2)

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

print((int(readline()) + int(readline())) * int(readline()) // 2)

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print(c*(a+b)//2)

Solution (Python):
import itertools
import math
import string
import collections
from collections import Counter
from collections import deque
from operator import itemgetter
import sys
sys.setrecursionlimit(2*10**5)
INF = 2**60


def readints():
    return list(map(int, input().split()))


def nCr(n, r):
    return math.factorial(n)//(math.factorial(n-r)*math.factorial(r))


def has_duplicates2(seq):
    seen = []
    for item in seq:
        if not(item in seen):
            seen.append(item)
    return len(seq) != len(seen)


def divisor(n):
    divisor = []
    for i in range(1, n+1):
        if n % i == 0:
            divisor.append(i)
    return divisor



dx = [-1, -1, -1, 0, 0, 1, 1, 1]
dy = [-1, 0, 1, -1, 1, -1, 0, 1]
a = int(input())
b = int(input())
h = int(input())
print(int(((a+b)*h)/2))

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 7)
f_inf = float('inf')
mod = 10 ** 9 + 7


def resolve():
    a = int(input())
    b = int(input())
    h = int(input())

    res = ((a + b) * h) // 2
    print(res)


if __name__ == '__main__':
    resolve()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int(((a+b)*h)/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
def printns(x): print('\n'.join(x))
def printni(x): print('\n'.join(list(map(str,x))))
inf = 10**17
mod = 10**9 + 7

a=I()
b=I()
h=I()
ans=int((a+b)*h/2)
print(ans)

Solution (Python):
import sys, heapq, bisect, math, fractions
from collections import deque

a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
from collections import deque
from heapq import heapify,heappop,heappush,heappushpop
from copy import copy,deepcopy
from itertools import product,permutations,combinations,combinations_with_replacement
from collections import defaultdict,Counter
from bisect import bisect_left,bisect_right


from functools import reduce
from pprint import pprint

INF = float("inf")

def myinput():
    return map(int,input().split())

def mylistinput(n):
    return [ list(myinput()) for _ in range(n) ]

def mycol(data,col):
    return [ row[col] for row in data ]

def mysort(data,col,reverse_flag):
    data.sort(key=lambda x:x[col],reverse=reverse_flag)
    return data

def mymax(data):
    M = -1*float("inf")
    for i in range(len(data)):
        m = max(data[i])
        M = max(M,m)
    return M

def mymin(data):
    m = float("inf")
    for i in range(len(data)):
        M = min(data[i])
        m = min(m,M)
    return m

def mycount(ls,x):
    
    l = bisect_left(ls,x)
    r = bisect_right(ls,x)
    return (r-l)

def myoutput(ls,space=True):
    if space:
        if len(ls)==0:
            print(" ")
        elif type(ls[0])==str:
            print(" ".join(ls))
        elif type(ls[0])==int:
            print(" ".join(map(str,ls)))
        else:
            print("Output Error")
    else:
        if len(ls)==0:
            print("")
        elif type(ls[0])==str:
            print("".join(ls))
        elif type(ls[0])==int:
            print("".join(map(str,ls)))
        else:
            print("Output Error")

a = int(input())
b = int(input())
h = int(input())
ans = (a+b)*h/2
print(int(ans))

Solution (Python):
a = int(input())
b = int(input())
h= int(input())

print((a+b)*h//2)

Solution (Python):
a, b, h = (int(input()) for i in range(3))
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
def main():
    a = int(input())
    b = int(input())
    h = int(input())

    print((a + b) * (h // 2))

if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(((a+b)*h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b= int(input())
h = int(input())

ans = (a+b)*h//2

print(ans)

Solution (Python):
from sys import stdin
def main():
    
    readline=stdin.readline
    a=int(readline())
    b=int(readline())
    h=int(readline())

    print((a+b)*h//2)
if __name__=="__main__":
    main()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print(int(((a + b) * c) / 2))

Solution (Python):
def main():
    a,b,h = (int(input()) for _ in range(3))
    print((a+b)*h//2)

if __name__ == '__main__':
    main()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
ans=((a+b)*h)//2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a,b,c=map(int,open(0));print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print((a+b)*h//2)

Solution (Python):


print((int(input())+int(input()))*int(input())//2)

Solution (Python):

def ABC_45_A():
    a = int(input())
    b = int(input())
    h = int(input())

    print(int((a+b)*h/2))


if __name__ == '__main__':

    ABC_45_A()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int(((a+b)*h)/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = (a+b)*h // 2
print(S)

Solution (Python):
a=input()
b=input()
h=input()
print((int(a)+int(b))*int(h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b) * h /2))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b)*h//2)

Solution (Python):
a, b, h = [int(input()) for i in range(3)]

print(round((a + b) * h / 2))

Solution (Python):
a,b,h=[int(input()) for i in range(3)]
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = int((a+b)*h/2)

print(S)

Solution (Python):
a,b,h=[int(input()) for i in range(3)]
area = (a + b) * h // 2
print(area)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a,b,h=map(int,open(0));print((a+b)*h//2)

Solution (Python):
a,b,h=[int(input())for i in range(3)]
print(((a+b)*h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):

def resolve():
    a = int(input())
    b = int(input())
    h = int(input())
    print((a+b)*h//2)
    
    


if '__main__' == __name__:
    resolve()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
a, b, h = [int(input()) for _ in range(3)]
print(((a + b) * h) // 2)

Solution (Python):
if __name__ == "__main__":
    a = int(input())
    b = int(input())
    c = int(input())
    print(int((a + b) * c * 0.5))

Solution (Python):
print((int(input())+int(input()))*int(input())//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a,b,h=[int(input()) for _ in range(3)]
print((a+b)*h//2)

Solution (Python):
import math
a = int(input())
b = int(input())
h = int(input())
print(math.floor((a+b)*h/2))

Solution (Python):


a=int(input())
b=int(input())
h=int(input())

area=(a+b)*h/2

print(int(area))

Solution (Python):
a=int(input())
b=int(input())
c=int(input())

print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
c=int(input())
c=c+int(input())
print(int(c*int(input())//2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
import sys
A = "".join(sys.stdin.readlines())
A = A.splitlines()
A = list(map(int,A))
print((A[0]+A[1]) * A[2]//2)

Solution (Python):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
inf = 10**17
mod = 10**9 + 7


a=I()
b=I()
h=I()
ans=(a+b)*h//2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = (a+b)*h/2

print(int(S))

Solution (Python):
a, b, h = map(int, open(0).read().split())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
S = (a+b)*h//2
print(S)

Solution (Python):
def resolve():
    a=int(input())
    b=int(input())
    h=int(input())
    print((a+b)*h//2)
resolve()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(int((a+b)*h/2))

Solution (Python):
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(str, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

a = INT()
b = INT()
h = INT()
print((a+b)*h//2)

Solution (Python):
up = int(input())
down = int(input())
height = int(input())

print(int((up + down)*height/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
c=int(input())
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b) * h // 2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a, b, h = [int(input()) for _ in range(3)]
print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):

a=int(input())
b=int(input())
h=int(input())

print((a+b)*h//2)

Solution (Python):
a = input()
b = input()
h = input()

print(  int(((int(a)+int(b))*int(h))/2) )

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print((a+b)*c//2)

Solution (Python):
a,b,c=[int(input()) for i in range(3)]
print(((a+b)*c)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

s = (a+b)*h/2

ss = int(s)
print(ss)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
S = ((a+b)*h)//2
print(S)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
c = int(input())

print(int(((a+b)*c)/2))

Solution (Python):
print((int(input())+int(input()))*int(input())//2)

Solution (Python):
a,b,h=[int(input()) for i in range(3)]
print((a+b)*h//2)

Solution (Python):
a,b,h= [int(input()) for i in range(3)]
print(int((a+b)*h/2))

Solution (Python):

a = int(input())
b = int(input())
h = int(input())
men = (a + b) * h // 2
print(men)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**7)
    from collections import Counter, deque
    
    from itertools import combinations, permutations, accumulate, groupby, product
    from bisect import bisect_left,bisect_right
    from heapq import heapify, heappop, heappush
    from math import floor, ceil
    

    
    

    a = int(input())
    b = int(input())
    h = int(input())
    print((a+b)*h//2)

if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
ans = (a + b) * h // 2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = (a+b) * h / 2
print(int(S))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h //2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
ans=(a+b)*h//2
print(ans)

Solution (Python):
a,b,h = (int(input()) for i in range(3))
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print('{:.0f}'.format((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
c = int(input())

ans = int((a+b) * c/2)
print(ans)

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

ans = (a + b) * h // 2
print(ans)

Solution (Python):
def solve(a, b, h):
    print(int((a + b) / 2 * h))



a = int(input())
b = int(input())
h = int(input())
solve(a, b, h)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
def resolve():
	t = []
	for _ in range(3):
		t.append(int(input()))
	a, b, h = t
	print(int((a+b)/2*h))
resolve()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h/2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a + b) * h / 2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
area = h * min(a, b) + h * abs(b - a) * 0.5
print(int(area))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print( (a+b)*h//2 )

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(h//2*(a+b))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(((a+b)*h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

area = ((a + b) / 2) * h

print(int(area))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

if a>b:
  print(int((((a-b)*h)/2)+(b*h)))
elif b>a:
  print(int((((b-a)*h)/2)+(a*h)))
else:
  print(int(a*h))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
s = (a + b) * h // 2
print(s)

Solution (Python):
x=int(input())
y=int(input())
z=int(input())
print(((x+y)*z)//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
import sys

stdin = sys.stdin
inf = 1 << 60
mod = 1000000007

ni      = lambda: int(ns())
nin     = lambda y: [ni() for _ in range(y)]
na      = lambda: list(map(int, stdin.readline().split()))
nan     = lambda y: [na() for _ in range(y)]
nf      = lambda: float(ns())
nfn     = lambda y: [nf() for _ in range(y)]
nfa     = lambda: list(map(float, stdin.readline().split()))
nfan    = lambda y: [nfa() for _ in range(y)]
ns      = lambda: stdin.readline().rstrip()
nsn     = lambda y: [ns() for _ in range(y)]
ncl     = lambda y: [list(ns()) for _ in range(y)]
nas     = lambda: stdin.readline().split()

a, b, h = nin(3)

print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
A=int(1/2*(a+b)*h)
print(A)

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

ans = (a + b)*h / 2

print(int(ans))

Solution (Python):
print(int((int(input())+int(input()))*int(input())/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
s = (a+b)*h/2
print(int(s))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
icase=45
if icase==45:
    a=int(input())
    b=int(input())
    h=int(input())
    print((a+b)*h//2)

Solution (Python):
def main():
    a = int(input())
    b = int(input())
    h = int(input())

    print(int((a+b)*h/2))

main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a + b) * h / 2))

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print(((a+b)*c)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

ans = (a + b) * h // 2
print(ans)

Solution (Python):
a = int(input().strip())
b = int(input().strip())
h = int(input().strip())

print((a+b) * (h//2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(int(((a+b)*h)/2))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
A = int(input())
B = int(input())
H = int(input())

print((A+B)*H//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
 
print(int((a + b) * h / 2))

Solution (Python):
a,b,h=eval('int(input()),'*3)
print(h*(a+b)//2)

Solution (Python):
a,b,h=eval('int(input()),'*3);print(h*(a+b)//2)

Solution (Python):

a = int(input())
b = int(input())
h = int(input())

print(int(((a + b) * h) / 2))

Solution (Python):
import math

a = int(input())
b = int(input())
h = int(input())
 
menseki = (a + b) * h / 2
 
print(math.floor(menseki))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
 
face = (a+b)*h//2
print(face)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = (a + b) * h / 2

print(int(S))

Solution (Python):
def I(): return int(input())
print((I()+I())*I()//2)

Solution (Python):
if __name__ == "__main__":
  a,b,h = map(int, [input() for i in range(3)])
  print(int((a+b)*h/2))

Solution (Python):
a, b, h = map(int, open(0).read().split())
print(int(((a+b)*h)/2))

Solution (Python):
import sys

input = sys.stdin.readline


def main():
    a = int(input())
    b = int(input())
    h = int(input())

    ans = (a + b) * h // 2
    print(ans)


if __name__ == "__main__":
    main()

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a,b,c = [int(input()) for i in range(3)]
print((a+b)*c//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
c = int(input())
print(int((a+b)/2*c))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(int((a+b)*h/2))

Solution (Python):
alpha = int(input())
beta = int(input())
charlie = int(input())

print(int((alpha + beta) * charlie / 2))

Solution (Python):
a,b,h = [int(input()) for i in range(3)]
print((a+b)*h//2)

Solution (Python):

a = int(input())
b = int(input())
h = int(input())
ans = (a + b) * h // 2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a = [int(input()) for i in range(3)]
ans = ((a[0]+a[1]) * a[2]) / 2

print(str(int(ans)))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print(int((a+b)*h/2))

Solution (Python):
a=[]
for i in range(3):
  a.append(int(input()))
  
print(int((a[0]+a[1])*a[2]/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
url = "https://atcoder.jp/contests/abc045/tasks/abc045_a"

def main():
    n, m, h = [int(input()) for i in range(3)]
    print(int((n + m) * h / 2))
if __name__ == '__main__':
    main()

Solution (Python):
url = "https://atcoder.jp/contests/abc045/tasks/abc045_a"

def main():
    n, m, h = [int(input()) for i in range(3)]
    print(int((n + m) * h / 2))
if __name__ == '__main__':
    main()

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a=int(input())
b=int(input())
h = int(input())
print(int((a+b)*h/2))

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a, b, h = [int(input()) for _ in range(3)]
print(int(((a + b) * h)/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
import sys
stdin = sys.stdin

ns = lambda: stdin.readline().rstrip()
ni = lambda: int(stdin.readline().rstrip())
nm = lambda: map(int, stdin.readline().split())
nl = lambda: list(map(int, stdin.readline().split()))

a=int(input())
b=int(input())
h=int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(((a + b) * h) // 2)

Solution (Python):
input_list = [int(input()) for i in range(3)]

S = int((input_list[0] + input_list[1])*input_list[2]/2)

print(S)

Solution (Python):
a, b, h = (int(input()) for _ in range(3))
print( (a+b)*h//2)

Solution (Python):
list_ = [int(input()) for i in range(3)]

S = int((list_[0] + list_[1])*list_[2]/2)

print(S)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print( (a + b) * h // 2)

Solution (Python):
a, b, h = [int(input()) for x in range(3)]
ans = (a + b) * h // 2
print(ans)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
ans = (a+b)*h//2
print(ans)

Solution (Python):
a = input()
b = input()
h = input()
print (a + b) * h / 2

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print(((a+b)*h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

S = ((a + b) * h) / 2

print(str(int(S)))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a + b) * h /2))

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(((a+b)*h)//2)

Solution (Python):
a=int(input())
b=int(input())
h=int(input())

print(((a+b)*h)//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print((a+b)*h//2)

Solution (Python):
a = int(input())
b = int(input())
h = int(input())

print(int((a + b)*h /2))

Solution (Python):
a =int(input())
b =int(input())
h = int(input())

answer = (a + b) * h / 2

print(int(answer))

Solution (Python):
print((int(input()) + int(input())) * int(input()) // 2)

Solution (Python):
import sys

a, b, h = map(int, sys.stdin.read().split())

def main():
    s = (a + b) * h // 2
    print(s)

if __name__ ==  '__main__':
    main()