#include int main(void) { long double a, b, c; scanf("%Lf,%Lf,%LF", &a, &b, &c); printf("%.10Lf\n", (a + b) * c / 2); }