package no091; import java.util.Scanner; public class Main { public static final int MAX = 10000000; public static void main(String[] args) { Scanner sc = new Scanner(System.in); int[] n = new int[3]; for(int i=0;i<3;i++) { n[i] = sc.nextInt(); } while(true) { int maxi = -1; int mini = -1; int max = -1<<29; int min = 1<<29; for(int i=0;i<3;i++) { if (n[i] < min) { min = n[i]; mini = i; }else if(n[i] > max) { max = n[i]; maxi = i; } } if (max - min <= 2) { break; } if (n[maxi] <= 2) { break; } n[mini]++; n[maxi]-=2; } System.out.println(Math.min(n[0],Math.min(n[1],n[2]))); } }