#include #include using namespace std; int main(){ long long factor = pow(10,9) + 7; double a, b, t; cin >> a >> b >> t; int expect = 0.5 * (a + b) * t; double cells = expect % factor; cout << cells << endl; return 0; }