#include <bits/stdc++.h>
using namespace std;
int a[5];
int main() {
  ios_base::sync_with_stdio(false);
  cin >> a[0] >> a[1] >> a[2];
  int s = a[0] + a[1] + a[2];
  int ans = 0;
  int i = 0;
  while (s > 0) {
    s -= min(a[i], 2);
    a[i] -= min(a[i], 2);
    ans++;
    i = (i + 1) % 3;
  }
  cout << ans + 29 << endl;
  return 0;
}
