import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	} main {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int P = scanner.nextInt(); P scanner.nextInt() scanner.nextInt scanner int Q = scanner.nextInt(); Q scanner.nextInt() scanner.nextInt scanner int R = scanner.nextInt(); R scanner.nextInt() scanner.nextInt scanner int x = P + Q; x P + Q P Q int y = Q + R; y Q + R Q R int z = R + P; z R + P R P int min = x; min x int[] data = { x, y, z}; data { x, y, z} x y z for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]); int i = 0; int i = 0; i 0 i < data.length i data.length data data.length i++ i++ i min = Math.min(min,data[i]); min = Math.min(min,data[i]) min Math.min(min,data[i]) Math.min Math min data[i] data i System.out.println(min) System.out.println System.out System System.out min String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int P = scanner.nextInt();
		int Q = scanner.nextInt();
		int R = scanner.nextInt();
		
		int x = P + Q;
		int y = Q + R;
		int z = R + P;
		
		int min = x;
		
		int[] data = { x, y, z};
        // 最小値を求める
        for(int i = 0; i < data.length; i++)
                min = Math.min(min,data[i]);
        System.out.println(min);
	}
}