r, g, b = sorted(map(int, input().split())) while b - r > 2: r += 1 b -= 2 r, g, b = sorted([r, g, b]) print(min(r, g, b))