import java.util.*; public class Exercise140{ public static void main (String[] args){ Scanner sc = new Scanner(System.in); int r = sc.nextInt(); int g = sc.nextInt(); int b = sc.nextInt(); while(Math.abs(r - g) > 1 || Math.abs(r - b) > 1) { int biggest = Math.max(Math.max(r, g), b); int smallest = Math.min(Math.min(r, g), b); if(biggest == r){ r -= 2; }else if(biggest == g){ g -= 2; }else if(biggest == b){ b -= 2; } if(smallest == r){ r++; }else if(smallest == g){ g++; }else if(smallest == b){ b++; } } System.out.println(Math.min(Math.min(r, g), b)); } }