#include <bits/stdc++.h>
using namespace std;
int main() {
  long long r, g, b, ans;
  cin >> r >> g >> b;
  ans = max(3 * ((r + 1) / 2) + 27, 3 * ((g + 1) / 2) + 28);
  ans = max(ans, 3 * ((b + 1) / 2) + 29);
  cout << ans << endl;
  return 0;
}
