#include #include #include using namespace std; #define RREP(i,s,e) for (int i = e-1; i >= s; i--) #define rrep(i,n) RREP(i,0,n) #define REP(i,s,e) for (int i = s; i < e; i++) #define rep(i,n) REP(i,0,n) int main() { int rgb[3], ans; rep (i,3) cin >> rgb[i]; ans = *min_element(rgb,rgb+3); rep (i,3) rgb[i] -= ans; sort(rgb,rgb+3); while (rgb[2] >= 3) { rgb[2] -= 2; rgb[0]++; sort(rgb,rgb+3); if (rgb[0] > 0) { ans++; rep (i,3) rgb[i]--; } } cout << ans << endl; return 0; }