// Nikita Golikov, 2023 #include using namespace std; using uint = unsigned int; using ll = long long; using ull = unsigned long long; #ifdef GOLIKOV #include "/Users/golikovnik/contests/debug.h" #else #define debug(...) ; #endif template bool smin(A& x, B&& y) { if (y < x) { x = y; return true; } return false; } template bool smax(A& x, B&& y) { if (x < y) { x = y; return true; } return false; } int main() { #ifdef GOLIKOV assert(freopen("in", "rt", stdin)); auto _clock_start = chrono::high_resolution_clock::now(); #endif ios::sync_with_stdio(false); cin.tie(nullptr); int a, b, c; cin >> a >> b >> c; int ans = 2 * a; if (c >= 2) { ans += 3 * (c / 2); ans += 2 * b; } cout << ans << '\n'; #ifdef GOLIKOV cerr << "Executed in " << chrono::duration_cast( chrono::high_resolution_clock::now() - _clock_start).count() << "ms." << endl; #endif return 0; }