#include <bits/stdc++.h>
using namespace std;
template <typename T>
T ABS(const T& val) {
  return val < 0 ? -val : val;
}
int main() {
  std::ios_base::sync_with_stdio(false);
  long long vals[3];
  while (cin >> vals[0] >> vals[1] >> vals[2]) {
    sort(vals, vals + 3);
    reverse(vals, vals + 3);
    cout << min((vals[0] + vals[1] + vals[2]) / 3,
                min(vals[0], vals[1] + vals[2]))
         << "\n";
  }
  return 0;
}
