#include <bits/stdc++.h>
using namespace std;
long long r, g, b;
long long cnt;
long long min(long long a, long long b, long long c) {
  long long m;
  if (a > b)
    m = b;
  else
    m = a;
  if (m > c) m = c;
  return m;
}
int main() {
  bool flag[3];
  while (~scanf("%lld%lld%lld", &r, &g, &b)) {
    flag[0] = (r % 3 == 0);
    flag[1] = (g % 3 == 0);
    flag[2] = (b % 3 == 0);
    if (flag[0] && flag[1] && flag[2])
      printf("%lld\n", (r + g + b) / 3);
    else {
      long long a[11];
      long long mr, mg, mb;
      long long mi;
      for (long long i = 0; i < 11; i++) a[i] = 0;
      mr = r % 3;
      mg = g % 3;
      mb = b % 3;
      if (r >= 3)
        a[0] = (r - mr + g - mg + b - mb - 3) / 3 + min(mr + 3, mg, mb);
      if (g >= 3)
        a[1] = (r - mr + g - mg + b - mb - 3) / 3 + min(mr, mg + 3, mb);
      if (b >= 3)
        a[2] = (r - mr + g - mg + b - mb - 3) / 3 + min(mr, mg, mb + 3);
      if (r >= 6)
        a[3] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr + 6, mg, mb);
      if (g >= 6)
        a[4] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr, mg + 6, mb);
      if (b >= 6)
        a[5] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr, mg, mb + 6);
      if (r >= 3 && g >= 3)
        a[6] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr + 3, mg + 3, mb);
      if (r >= 3 && b >= 3)
        a[7] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr + 3, mg, mb + 3);
      if (g >= 3 && b >= 3)
        a[8] = (r - mr + g - mg + b - mb - 6) / 3 + min(mr, mg + 3, mb + 3);
      a[9] = ((r - mr + g - mg + b - mb) / 3) + min(mr, mg, mb);
      if (r >= 3 && g >= 3 && b >= 3)
        a[10] =
            ((r - mr + g - mg + b - mb - 9) / 3) + min(mr + 3, mg + 3, mb + 3);
      mi = a[0];
      for (long long i = 0; i < 11; i++) {
        if (a[i] > mi) mi = a[i];
      }
      printf("%lld\n", mi);
    }
  }
  return 0;
}
