#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int r = 0, g = 0, b = 0, min = 29;
  char cur = 0;
  cin >> r >> g >> b;
  while (r || g || b) {
    switch (cur) {
      case 0:
        if (r > 0) {
          r -= 2;
          if (r < 0) r = 0;
        }
        cur++;
        min++;
        break;
      case 1:
        if (g > 0) {
          g -= 2;
          if (g < 0) g = 0;
        }
        cur++;
        min++;
        break;
      case 2:
        if (b > 0) {
          b -= 2;
          if (b < 0) b = 0;
        }
        cur = 0;
        min++;
        break;
    }
  }
  cout << min;
  return 0;
}
