#include <bits/stdc++.h>
using namespace std;
int main() {
  int r, g, b, m = 29, f, i, n = 0;
  cin >> r >> g >> b;
  if (r >= 2) {
    if (r % 2 == 0)
      r /= 2;
    else
      r = (r / 2) + 1;
  }
  if (g >= 2) {
    if (g % 2 == 0)
      g /= 2;
    else
      g = (g / 2) + 1;
  }
  if (b >= 2) {
    if (b % 2 == 0)
      b /= 2;
    else
      b = (b / 2) + 1;
  }
  f = r + g + b;
  for (i = 1; i <= f; i++) {
    while (r > 0 || g > 0 || b > 0) {
      if (r <= 0 && g <= 0 && b <= 0) n++;
      m++;
      r--;
      if (r <= 0 && g <= 0 && b <= 0) n++;
      m++;
      g--;
      if (r <= 0 && g <= 0 && b <= 0) n++;
      m++;
      b--;
    }
  }
  cout << m - n;
}
