#include <bits/stdc++.h>
using namespace std;
long long s[10];
int main() {
  cin >> s[0] >> s[1] >> s[2];
  sort(s, s + 3);
  if ((s[1] - s[0]) % 2 == 0) {
    cout << s[1] << endl;
  } else {
    cout << s[2] << endl;
  }
  return 0;
}
