#include <bits/stdc++.h>
using namespace std;
const double EPS = 1e-10;
const double INF = 1000 * 1000 * 1000 + 7;
long long calc(long long a, long long b, long long c) {
  long long M, m;
  long long res = 0;
  M = max(a, b);
  m = min(a, b);
  res += m;
  c += m;
  if (c % 2 == 0)
    res += min(M - m, c);
  else
    res += M - m;
  return res;
}
int main() {
  long long a, b, c;
  while (cin >> a >> b >> c) {
    long long res = a + b + c - 1;
    if ((a + b) % 2 == 0) {
      res = min(res, calc(a, b, c));
    }
    if ((b + c) % 2 == 0) {
      res = min(res, calc(b, c, a));
    }
    if ((c + a) % 2 == 0) {
      res = min(res, calc(c, a, b));
    }
    cout << res << endl;
  }
  return 0;
}
