#include <bits/stdc++.h>
using namespace std;
const long long maxN = 1e6 + 5;
const long long inf = 1e10;
const long long mod = 1e9 + 7;
long long r, b, g;
int main() {
  ios_base::sync_with_stdio(0);
  cin >> r >> g >> b;
  long long cs = 0;
  while (1) {
    if (r == 0 && g == 0 && b == 0) break;
    if (cs % 3 == 0) r = max(0LL, r - 2);
    if (cs % 3 == 1) g = max(0LL, g - 2);
    if (cs % 3 == 2) b = max(0LL, b - 2);
    cs++;
  }
  cout << cs + 29;
  return 0;
}
