node_ids
listlengths
4
1.4k
edge_index
listlengths
1
2.22k
text
listlengths
4
1.4k
source
stringlengths
14
427k
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 2, 13, 13, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 2, 2, 17, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 79, 8 ], [ 79, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 11, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 11, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 11, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 40, 45 ], [ 35, 46 ], [ 46, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 51, 53 ], [ 53, 54 ], [ 53, 55 ], [ 46, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 57, 62 ], [ 46, 63 ], [ 63, 64 ], [ 64, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 64, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 69, 75 ], [ 9, 76 ], [ 76, 77 ], [ 0, 78 ], [ 78, 79 ], [ 78, 80 ] ]
[ "import java.util.*;\nimport java.math.BigInteger;\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }\n}", "import java.util.*;", "util.*", "java", "import java.math.BigInteger;", "BigInteger", "java.math", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }", "k <= a", "k", "a", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }", "a < k && k <= a+b", "a < k", "a", "k", "k <= a+b", "k", "a+b", "a", "b", "{\n System.out.println(a);\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n System.out.println(2*a + b - k);\n }", "System.out.println(2*a + b - k)", "System.out.println", "System.out", "System", "System.out", "2*a + b - k", "2*a + b", "2*a", "2", "a", "b", "k", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n } else if (a < k && k <= a+b) {\n System.out.println(a);\n } else {\n System.out.println(2*a + b - k);\n }\n }\n}", "Main" ]
import java.util.*; import java.math.BigInteger; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); if (k <= a) { System.out.println(k); } else if (a < k && k <= a+b) { System.out.println(a); } else { System.out.println(2*a + b - k); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 42, 2, 2, 13, 17, 2, 13, 17, 30, 0, 13, 17, 40, 13, 40, 13, 42, 2, 2, 13, 17, 2, 13, 17, 30, 40, 13, 40, 13, 42, 2, 2, 13, 17, 2, 13, 17, 30, 0, 13, 17, 40, 13, 40, 13, 4, 18, 13, 13, 23, 13, 23, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 135, 17 ], [ 135, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 21, 23 ], [ 23, 24 ], [ 23, 25 ], [ 20, 26 ], [ 26, 27 ], [ 26, 28 ], [ 28, 29 ], [ 28, 30 ], [ 20, 31 ], [ 31, 32 ], [ 31, 33 ], [ 20, 34 ], [ 34, 35 ], [ 34, 36 ], [ 20, 37 ], [ 37, 38 ], [ 37, 39 ], [ 20, 40 ], [ 40, 41 ], [ 41, 42 ], [ 40, 43 ], [ 40, 44 ], [ 40, 45 ], [ 20, 46 ], [ 46, 47 ], [ 47, 48 ], [ 18, 49 ], [ 49, 50 ], [ 135, 51 ], [ 51, 52 ], [ 51, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 59, 60 ], [ 55, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 64, 65 ], [ 55, 66 ], [ 66, 67 ], [ 66, 68 ], [ 68, 69 ], [ 69, 70 ], [ 55, 71 ], [ 71, 72 ], [ 71, 73 ], [ 73, 74 ], [ 74, 75 ], [ 55, 76 ], [ 76, 77 ], [ 76, 78 ], [ 55, 79 ], [ 79, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 80, 84 ], [ 84, 85 ], [ 84, 86 ], [ 79, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 87, 91 ], [ 91, 92 ], [ 87, 93 ], [ 93, 94 ], [ 55, 95 ], [ 95, 96 ], [ 96, 97 ], [ 97, 98 ], [ 97, 99 ], [ 96, 100 ], [ 100, 101 ], [ 100, 102 ], [ 95, 103 ], [ 103, 104 ], [ 104, 105 ], [ 103, 106 ], [ 106, 107 ], [ 55, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 110, 112 ], [ 109, 113 ], [ 113, 114 ], [ 113, 115 ], [ 108, 116 ], [ 116, 117 ], [ 117, 118 ], [ 117, 119 ], [ 116, 120 ], [ 120, 121 ], [ 116, 122 ], [ 122, 123 ], [ 55, 124 ], [ 124, 125 ], [ 125, 126 ], [ 124, 127 ], [ 53, 128 ], [ 128, 129 ], [ 53, 130 ], [ 130, 131 ], [ 53, 132 ], [ 132, 133 ], [ 0, 134 ], [ 134, 135 ], [ 134, 136 ] ]
[ "import java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.PrintWriter;\nimport java.util.Scanner;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n */\npublic class Main\n{\n public static void main(String[] args)\n {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class Task\n {\n public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }\n\n }\n}\n", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.util.Scanner;", "Scanner", "java.util", "public class Main\n{\n public static void main(String[] args)\n {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class Task\n {\n public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }\n\n }\n}", "Main", "public static void main(String[] args)\n {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "Scanner in = new Scanner(inputStream);", "in", "new Scanner(inputStream)", "PrintWriter out = new PrintWriter(outputStream);", "out", "new PrintWriter(outputStream)", "Task solver = new Task();", "solver", "new Task()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class Task\n {\n public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }\n\n }", "Task", "public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }", "solve", "{\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }", "int A = in.nextInt();", "A", "in.nextInt()", "in.nextInt", "in", "int B = in.nextInt();", "B", "in.nextInt()", "in.nextInt", "in", "int C = in.nextInt();", "C", "in.nextInt()", "in.nextInt", "in", "int K = in.nextInt();", "K", "in.nextInt()", "in.nextInt", "in", "int sum = 0;", "sum", "0", "while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }", "A > 0 && K > 0", "A > 0", "A", "0", "K > 0", "K", "0", "{\n sum += 1;\n A--;\n K--;\n }", "sum += 1", "sum", "1", "A--", "A", "K--", "K", "while (B > 0 && K > 0)\n {\n B--;\n K--;\n }", "B > 0 && K > 0", "B > 0", "B", "0", "K > 0", "K", "0", "{\n B--;\n K--;\n }", "B--", "B", "K--", "K", "while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }", "C > 0 && K > 0", "C > 0", "C", "0", "K > 0", "K", "0", "{\n sum -= 1;\n C--;\n K--;\n }", "sum -= 1", "sum", "1", "C--", "C", "K--", "K", "out.println(sum)", "out.println", "out", "sum", "int testNumber", "testNumber", "Scanner in", "in", "PrintWriter out", "out", "public class Main\n{\n public static void main(String[] args)\n {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class Task\n {\n public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }\n\n }\n}", "public class Main\n{\n public static void main(String[] args)\n {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class Task\n {\n public void solve(int testNumber, Scanner in, PrintWriter out)\n {\n int A = in.nextInt();\n int B = in.nextInt();\n int C = in.nextInt();\n int K = in.nextInt();\n\n int sum = 0;\n\n while (A > 0 && K > 0)\n {\n sum += 1;\n A--;\n K--;\n }\n while (B > 0 && K > 0)\n {\n B--;\n K--;\n }\n while (C > 0 && K > 0)\n {\n sum -= 1;\n C--;\n K--;\n }\n out.println(sum);\n }\n\n }\n}", "Main" ]
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.PrintWriter; import java.util.Scanner; /** * Built using CHelper plug-in * Actual solution is at the top */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; Scanner in = new Scanner(inputStream); PrintWriter out = new PrintWriter(outputStream); Task solver = new Task(); solver.solve(1, in, out); out.close(); } static class Task { public void solve(int testNumber, Scanner in, PrintWriter out) { int A = in.nextInt(); int B = in.nextInt(); int C = in.nextInt(); int K = in.nextInt(); int sum = 0; while (A > 0 && K > 0) { sum += 1; A--; K--; } while (B > 0 && K > 0) { B--; K--; } while (C > 0 && K > 0) { sum -= 1; C--; K--; } out.println(sum); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 18, 13, 13, 8, 2, 2, 13, 13, 13, 8, 2, 13, 13, 2, 17, 13, 2, 17, 13, 2, 2, 17, 13, 2, 17, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 67, 5 ], [ 67, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 34, 35 ], [ 34, 36 ], [ 32, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 37, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 43, 47 ], [ 47, 48 ], [ 47, 49 ], [ 43, 50 ], [ 50, 51 ], [ 50, 52 ], [ 37, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 59, 63 ], [ 6, 64 ], [ 64, 65 ], [ 0, 66 ], [ 66, 67 ], [ 66, 68 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}\n}", "Main", "public static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}", "main", "{\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "System.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b))", "System.out.println", "System.out", "System", "System.out", "a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b)", "a+b>=k", "a+b", "a", "b", "k", "(a>=k ? 1*k : 1*a)", "a>=k", "a", "k", "1*k", "1", "k", "1*a", "1", "a", "1*a-1*(k-a-b)", "1*a", "1", "a", "1*(k-a-b)", "1", "(k-a-b)", "k-a-b", "k", "a", "b", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tSystem.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b));\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); System.out.println(a+b>=k ? (a>=k ? 1*k : 1*a) : 1*a-1*(k-a-b)); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 13, 41, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 4, 18, 13, 17, 2, 13, 13, 0, 13, 4, 18, 13, 17, 2, 13, 13, 0, 13, 4, 18, 13, 13, 13, 0, 13, 4, 18, 13, 17, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 88, 5 ], [ 88, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 40, 41 ], [ 41, 42 ], [ 40, 43 ], [ 40, 44 ], [ 8, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 48, 49 ], [ 47, 50 ], [ 47, 51 ], [ 51, 52 ], [ 51, 53 ], [ 8, 54 ], [ 54, 55 ], [ 54, 56 ], [ 56, 57 ], [ 57, 58 ], [ 56, 59 ], [ 56, 60 ], [ 60, 61 ], [ 60, 62 ], [ 8, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 66, 67 ], [ 65, 68 ], [ 65, 69 ], [ 8, 70 ], [ 70, 71 ], [ 70, 72 ], [ 72, 73 ], [ 73, 74 ], [ 72, 75 ], [ 72, 76 ], [ 76, 77 ], [ 76, 78 ], [ 8, 79 ], [ 79, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 79, 84 ], [ 6, 85 ], [ 85, 86 ], [ 0, 87 ], [ 87, 88 ], [ 87, 89 ] ]
[ "import java.util.*;\n\npublic class Main {\n public static void main (String[] args) {\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main (String[] args) {\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }\n}", "Main", "public static void main (String[] args) {\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "Integer A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "Integer B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "Integer C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "Integer K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int count = K;", "count", "K", "int rst = 0;", "rst", "0", "rst += Math.min(count, A)", "rst", "Math.min(count, A)", "Math.min", "Math", "count", "A", "count = Math.max(0, count - A)", "count", "Math.max(0, count - A)", "Math.max", "Math", "0", "count - A", "count", "A", "count = Math.max(0, count - B)", "count", "Math.max(0, count - B)", "Math.max", "Math", "0", "count - B", "count", "B", "rst -= Math.min(count, C)", "rst", "Math.min(count, C)", "Math.min", "Math", "count", "C", "count = Math.max(0, count - C)", "count", "Math.max(0, count - C)", "Math.max", "Math", "0", "count - C", "count", "C", "System.out.println(rst)", "System.out.println", "System.out", "System", "System.out", "rst", "String[] args", "args", "public class Main {\n public static void main (String[] args) {\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }\n}", "public class Main {\n public static void main (String[] args) {\n Scanner sc = new Scanner(System.in);\n\n Integer A = sc.nextInt();\n Integer B = sc.nextInt();\n Integer C = sc.nextInt();\n Integer K = sc.nextInt();\n\n int count = K;\n int rst = 0;\n\n // A \n rst += Math.min(count, A);\n count = Math.max(0, count - A);\n\n // B \n count = Math.max(0, count - B);\n\n // C \n rst -= Math.min(count, C);\n count = Math.max(0, count - C);\n\n System.out.println(rst);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main (String[] args) { Scanner sc = new Scanner(System.in); Integer A = sc.nextInt(); Integer B = sc.nextInt(); Integer C = sc.nextInt(); Integer K = sc.nextInt(); int count = K; int rst = 0; // A rst += Math.min(count, A); count = Math.max(0, count - A); // B count = Math.max(0, count - B); // C rst -= Math.min(count, C); count = Math.max(0, count - C); System.out.println(rst); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 14, 2, 2, 2, 13, 13, 13, 17, 30, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 2, 13, 17, 2, 13, 17, 30, 41, 13, 13, 41, 13, 2, 2, 13, 17, 2, 13, 17, 0, 13, 2, 2, 13, 13, 13, 0, 13, 2, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 111, 5 ], [ 111, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 8, 15 ], [ 15, 16 ], [ 15, 17 ], [ 8, 18 ], [ 18, 19 ], [ 18, 20 ], [ 8, 21 ], [ 21, 22 ], [ 21, 23 ], [ 8, 24 ], [ 24, 25 ], [ 24, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 35, 36 ], [ 8, 37 ], [ 37, 38 ], [ 37, 39 ], [ 39, 40 ], [ 40, 41 ], [ 8, 42 ], [ 42, 43 ], [ 42, 44 ], [ 44, 45 ], [ 45, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 50, 50 ], [ 50, 51 ], [ 50, 52 ], [ 50, 53 ], [ 48, 54 ], [ 47, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 56, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 67, 71 ], [ 71, 72 ], [ 71, 73 ], [ 47, 74 ], [ 74, 75 ], [ 75, 76 ], [ 75, 77 ], [ 74, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 80, 84 ], [ 84, 85 ], [ 84, 86 ], [ 74, 87 ], [ 87, 88 ], [ 87, 89 ], [ 90, 90 ], [ 90, 91 ], [ 90, 92 ], [ 90, 93 ], [ 74, 94 ], [ 94, 95 ], [ 94, 96 ], [ 96, 97 ], [ 96, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 8, 102 ], [ 102, 103 ], [ 103, 104 ], [ 104, 105 ], [ 104, 106 ], [ 102, 107 ], [ 6, 108 ], [ 108, 109 ], [ 0, 110 ], [ 110, 111 ], [ 110, 112 ] ]
[ "import java.util.Scanner;\n\npublic class Main{\n\n public static void main(String []args){\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main{\n\n public static void main(String []args){\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }\n\n}", "Main", "public static void main(String []args){\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a=0;", "a", "0", "int b=0;", "b", "0", "int c=0;", "c", "0", "int d=0;", "d", "0", "int score=0;", "score", "0", "a=sc.nextInt()", "a", "sc.nextInt()", "sc.nextInt", "sc", "b=sc.nextInt()", "b", "sc.nextInt()", "sc.nextInt", "sc", "c=sc.nextInt()", "c", "sc.nextInt()", "sc.nextInt", "sc", "d=sc.nextInt()", "d", "sc.nextInt()", "sc.nextInt", "sc", "if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }", "d-a-b<=0", "d-a-b", "d-a-b", "d", "a", "b", "0", "{\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }", "if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }", "a>=d", "a", "d", "{\n score=d;\n }", "score=d", "score", "d", "{\n score = a*1+b*0;\n }", "score = a*1+b*0", "score", "a*1+b*0", "a*1", "a", "1", "b*0", "b", "0", "{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }", "int temp=d;", "temp", "d", "int tscore=a*1+b*0;", "tscore", "a*1+b*0", "a*1", "a", "1", "b*0", "b", "0", "temp=d-a-b", "temp", "d-a-b", "d-a-b", "d", "a", "b", "score=tscore+temp*-1", "score", "tscore+temp*-1", "tscore", "temp*-1", "temp", "-1", "1", "System.out.print(score)", "System.out.print", "System.out", "System", "System.out", "score", "String []args", "args", "public class Main{\n\n public static void main(String []args){\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }\n\n}", "public class Main{\n\n public static void main(String []args){\n Scanner sc = new Scanner(System.in);\n int a=0;\n int b=0;\n int c=0;\n int d=0;\n int score=0;\n a=sc.nextInt();\n b=sc.nextInt();\n c=sc.nextInt();\n d=sc.nextInt();\n\n if(d-a-b<=0){\n if(a>=d){\n score=d;\n }else {\n score = a*1+b*0;\n }\n }else{\n int temp=d;\n int tscore=a*1+b*0;\n temp=d-a-b;\n score=tscore+temp*-1;\n\n\n\n\n\n\n\n\n }\n\n\n\n\n System.out.print(score);\n\n\n\n }\n\n}", "Main" ]
import java.util.Scanner; public class Main{ public static void main(String []args){ Scanner sc = new Scanner(System.in); int a=0; int b=0; int c=0; int d=0; int score=0; a=sc.nextInt(); b=sc.nextInt(); c=sc.nextInt(); d=sc.nextInt(); if(d-a-b<=0){ if(a>=d){ score=d; }else { score = a*1+b*0; } }else{ int temp=d; int tscore=a*1+b*0; temp=d-a-b; score=tscore+temp*-1; } System.out.print(score); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 17, 30, 0, 13, 13, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 86, 5 ], [ 86, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 47, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 55, 59 ], [ 59, 60 ], [ 59, 61 ], [ 55, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 62, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 74, 75 ], [ 74, 76 ], [ 8, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 6, 83 ], [ 83, 84 ], [ 0, 85 ], [ 85, 86 ], [ 85, 87 ] ]
[ "import java.util.*;\n\npublic class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }\n}\n", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }\n}", "Main", "public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }", "main", "{\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = Integer.parseInt(sc.next());", "a", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int b = Integer.parseInt(sc.next());", "b", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int c = Integer.parseInt(sc.next());", "c", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int k = Integer.parseInt(sc.next());", "k", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int ans = 0;", "ans", "0", "if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }", "a >= k", "a", "k", "{\n ans = k;\n }", "ans = k", "ans", "k", "{\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }", "ans += a", "ans", "a", "k -= a", "k", "a", "if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }", "b >= k", "b", "k", "{\n k = 0;\n }", "k = 0", "k", "0", "{\n k -= b;\n ans -= k;\n }", "k -= b", "k", "b", "ans -= k", "ans", "k", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }\n}", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n\n if (a >= k) {\n ans = k;\n } else {\n ans += a;\n k -= a;\n if (b >= k) {\n k = 0;\n } else {\n k -= b;\n ans -= k;\n }\n }\n System.out.println(ans);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = Integer.parseInt(sc.next()); int b = Integer.parseInt(sc.next()); int c = Integer.parseInt(sc.next()); int k = Integer.parseInt(sc.next()); int ans = 0; if (a >= k) { ans = k; } else { ans += a; k -= a; if (b >= k) { k = 0; } else { k -= b; ans -= k; } } System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 2, 2, 13, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 70, 5 ], [ 70, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 53, 53 ], [ 53, 54 ], [ 53, 55 ], [ 53, 56 ], [ 35, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 8, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 6, 67 ], [ 67, 68 ], [ 0, 69 ], [ 69, 70 ], [ 69, 71 ] ]
[ "import java.util.Scanner;\n//import java.util.Arrays;\npublic class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "Main", "public static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "long a = sc.nextLong();", "a", "sc.nextLong()", "sc.nextLong", "sc", "long b = sc.nextLong();", "b", "sc.nextLong()", "sc.nextLong", "sc", "long c = sc.nextLong();", "c", "sc.nextLong()", "sc.nextLong", "sc", "long k = sc.nextLong();", "k", "sc.nextLong()", "sc.nextLong", "sc", "long result = 0;", "result", "0", "if(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}", "k >= a", "k", "a", "{\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}", "result += a", "result", "a", "if(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}", "k > a + b", "k", "a + b", "a", "b", "{\n\t\t\t\tresult -= k - a - b;\n\t\t\t}", "result -= k - a - b", "result", "k - a - b", "k - a - b", "k", "a", "b", "{\n\t\t\tresult += k;\n\t\t}", "result += k", "result", "k", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "String[] args", "args", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t//\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong result = 0;\n\t\tif(k >= a){\n\t\t\tresult += a;\n\t\t\tif(k > a + b){\n\t\t\t\tresult -= k - a - b;\n\t\t\t}\n\t\t}else{\n\t\t\tresult += k;\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "Main" ]
import java.util.Scanner; //import java.util.Arrays; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); // long a = sc.nextLong(); long b = sc.nextLong(); long c = sc.nextLong(); long k = sc.nextLong(); long result = 0; if(k >= a){ result += a; if(k > a + b){ result -= k - a - b; } }else{ result += k; } System.out.println(result); } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 20, 41, 13, 17, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 2, 17, 17, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 0, 13, 13, 14, 2, 13, 17, 30, 0, 13, 4, 18, 13, 13, 13, 4, 18, 18, 13, 13, 13, 12, 13, 30, 4, 18, 20, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 101, 5 ], [ 101, 6 ], [ 6, 7 ], [ 6, 8 ], [ 101, 9 ], [ 9, 10 ], [ 9, 11 ], [ 101, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 14, 16 ], [ 101, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 19, 21 ], [ 101, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 24, 26 ], [ 101, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 29, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 29, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 43, 44 ], [ 29, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 48, 49 ], [ 29, 50 ], [ 50, 51 ], [ 50, 52 ], [ 29, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 57, 61 ], [ 61, 62 ], [ 61, 63 ], [ 53, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 64, 68 ], [ 68, 69 ], [ 68, 70 ], [ 29, 71 ], [ 71, 72 ], [ 71, 73 ], [ 29, 74 ], [ 74, 75 ], [ 75, 76 ], [ 75, 77 ], [ 74, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 82, 83 ], [ 81, 84 ], [ 81, 85 ], [ 29, 86 ], [ 86, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 86, 91 ], [ 101, 92 ], [ 92, 93 ], [ 92, 94 ], [ 94, 95 ], [ 95, 96 ], [ 96, 97 ], [ 92, 98 ], [ 98, 99 ], [ 0, 100 ], [ 100, 101 ], [ 100, 102 ] ]
[ "import java.util.*;\n\npublic class Main {\n\tScanner sc = new Scanner(System.in);\n\tfinal int MOD = 1000000007;\n\tfinal int MAX = Integer.MAX_VALUE;\n\tfinal long LMAX = Long.MAX_VALUE;\n\tint len = (int)1e6 + 1;\n\t\n\tvoid doIt() {\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tpublic static void main(String[] args) {\n\t\tnew Main().doIt();\n\t}\n\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tScanner sc = new Scanner(System.in);\n\tfinal int MOD = 1000000007;\n\tfinal int MAX = Integer.MAX_VALUE;\n\tfinal long LMAX = Long.MAX_VALUE;\n\tint len = (int)1e6 + 1;\n\t\n\tvoid doIt() {\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tpublic static void main(String[] args) {\n\t\tnew Main().doIt();\n\t}\n\n}", "Main", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "final int MOD = 1000000007;", "MOD", "1000000007", "final int MAX = Integer.MAX_VALUE;", "MAX", "Integer.MAX_VALUE", "Integer", "Integer.MAX_VALUE", "final long LMAX = Long.MAX_VALUE;", "LMAX", "Long.MAX_VALUE", "Long", "Long.MAX_VALUE", "int len = (int)1e6 + 1;", "len", "(int)1e6 + 1", "(int)1e6", "1", "void doIt() {\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "doIt", "{\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int sum = 0;", "sum", "0", "if(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}", "K >= A", "K", "A", "{\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}", "K -= A", "K", "A", "sum += A", "sum", "A", "{\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}", "sum += K", "sum", "K", "K = 0", "K", "0", "K -= B", "K", "B", "if(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}", "K >= 0", "K", "0", "{\n\t\t\tsum -= Math.min(K, C);\n\t\t}", "sum -= Math.min(K, C)", "sum", "Math.min(K, C)", "Math.min", "Math", "K", "C", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "public static void main(String[] args) {\n\t\tnew Main().doIt();\n\t}", "main", "{\n\t\tnew Main().doIt();\n\t}", "new Main().doIt()", "new Main().doIt", "new Main()", "String[] args", "args", "public class Main {\n\tScanner sc = new Scanner(System.in);\n\tfinal int MOD = 1000000007;\n\tfinal int MAX = Integer.MAX_VALUE;\n\tfinal long LMAX = Long.MAX_VALUE;\n\tint len = (int)1e6 + 1;\n\t\n\tvoid doIt() {\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tpublic static void main(String[] args) {\n\t\tnew Main().doIt();\n\t}\n\n}", "public class Main {\n\tScanner sc = new Scanner(System.in);\n\tfinal int MOD = 1000000007;\n\tfinal int MAX = Integer.MAX_VALUE;\n\tfinal long LMAX = Long.MAX_VALUE;\n\tint len = (int)1e6 + 1;\n\t\n\tvoid doIt() {\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\t\tif(K >= A) {\n\t\t\tK -= A;\n\t\t\tsum += A;\n\t\t}\n\t\telse {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tK -= B;\n\t\tif(K >= 0) {\n\t\t\tsum -= Math.min(K, C);\n\t\t}\n\t\tSystem.out.println(sum);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n\t\n\tpublic static void main(String[] args) {\n\t\tnew Main().doIt();\n\t}\n\n}", "Main" ]
import java.util.*; public class Main { Scanner sc = new Scanner(System.in); final int MOD = 1000000007; final int MAX = Integer.MAX_VALUE; final long LMAX = Long.MAX_VALUE; int len = (int)1e6 + 1; void doIt() { int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int sum = 0; if(K >= A) { K -= A; sum += A; } else { sum += K; K = 0; } K -= B; if(K >= 0) { sum -= Math.min(K, C); } System.out.println(sum); } public static void main(String[] args) { new Main().doIt(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 40, 13, 14, 2, 13, 17, 30, 0, 13, 13, 14, 2, 13, 17, 30, 42, 2, 13, 17, 30, 40, 13, 40, 13, 0, 13, 2, 13, 17, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 115, 5 ], [ 115, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 55, 56 ], [ 55, 57 ], [ 47, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 59, 64 ], [ 64, 65 ], [ 64, 66 ], [ 59, 67 ], [ 67, 68 ], [ 68, 69 ], [ 59, 70 ], [ 71, 71 ], [ 71, 72 ], [ 72, 73 ], [ 71, 74 ], [ 74, 75 ], [ 8, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 76, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 8, 84 ], [ 84, 85 ], [ 85, 86 ], [ 85, 87 ], [ 84, 88 ], [ 88, 89 ], [ 89, 90 ], [ 90, 91 ], [ 90, 92 ], [ 89, 93 ], [ 93, 94 ], [ 94, 95 ], [ 93, 96 ], [ 96, 97 ], [ 8, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 100, 102 ], [ 8, 103 ], [ 103, 104 ], [ 104, 105 ], [ 105, 106 ], [ 105, 107 ], [ 103, 108 ], [ 8, 109 ], [ 109, 110 ], [ 110, 111 ], [ 6, 112 ], [ 112, 113 ], [ 0, 114 ], [ 114, 115 ], [ 114, 116 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String args[]){\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }\n \n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String args[]){\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }\n \n}", "Main", "public static void main(String args[]){\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = Integer.parseInt(sc.next());", "A", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int B = Integer.parseInt(sc.next());", "B", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int C = Integer.parseInt(sc.next());", "C", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int K = Integer.parseInt(sc.next());", "K", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int max=0;", "max", "0", "if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }", "K < A", "K", "A", "{\n max = K;\n K=0;\n }", "max = K", "max", "K", "K=0", "K", "0", "{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }", "for(int i=0; i<A; i++){\n max++;\n K--;\n }", "int i=0;", "int i=0;", "i", "0", "i<A", "i", "A", "i++", "i++", "i", "{\n max++;\n K--;\n }", "{\n max++;\n K--;\n }", "max++", "max", "K--", "K", "if(K > 0){\n K-=B;\n }", "K > 0", "K", "0", "{\n K-=B;\n }", "K-=B", "K", "B", "if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }", "K > 0", "K", "0", "{\n while(K > 0){\n K--;\n max--;\n }\n }", "while(K > 0){\n K--;\n max--;\n }", "K > 0", "K", "0", "{\n K--;\n max--;\n }", "K--", "K", "max--", "max", "A=C-1", "A", "C-1", "C", "1", "System.out.println(max)", "System.out.println", "System.out", "System", "System.out", "max", "sc.close()", "sc.close", "sc", "String args[]", "args", "public class Main {\n\n public static void main(String args[]){\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }\n \n}", "public class Main {\n\n public static void main(String args[]){\n Scanner sc = new Scanner(System.in);\n int A = Integer.parseInt(sc.next());\n int B = Integer.parseInt(sc.next());\n int C = Integer.parseInt(sc.next());\n int K = Integer.parseInt(sc.next());\n int max=0;\n\n\n if( K < A){\n max = K;\n K=0;\n }else{\n for(int i=0; i<A; i++){\n max++;\n K--;\n }\n }\n if(K > 0){\n K-=B;\n }\n if(K > 0){\n while(K > 0){\n K--;\n max--;\n }\n }\n A=C-1;\n\n System.out.println(max);\n\n sc.close();\n }\n \n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String args[]){ Scanner sc = new Scanner(System.in); int A = Integer.parseInt(sc.next()); int B = Integer.parseInt(sc.next()); int C = Integer.parseInt(sc.next()); int K = Integer.parseInt(sc.next()); int max=0; if( K < A){ max = K; K=0; }else{ for(int i=0; i<A; i++){ max++; K--; } } if(K > 0){ K-=B; } if(K > 0){ while(K > 0){ K--; max--; } } A=C-1; System.out.println(max); sc.close(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 14, 2, 13, 13, 30, 14, 2, 13, 2, 13, 13, 30, 0, 13, 2, 2, 13, 13, 13, 0, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 75, 5 ], [ 75, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 8, 34 ], [ 34, 35 ], [ 35, 36 ], [ 35, 37 ], [ 34, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 42, 44 ], [ 39, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 49, 49 ], [ 49, 50 ], [ 49, 51 ], [ 49, 52 ], [ 45, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 55, 57 ], [ 39, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 34, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 8, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 66, 71 ], [ 6, 72 ], [ 72, 73 ], [ 0, 74 ], [ 74, 75 ], [ 74, 76 ] ]
[ "import java.util.*;\npublic class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }\n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int sum;", "sum", "if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }", "a<=k", "a", "k", "{\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n }", "if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }", "b<=k-a", "b", "k-a", "k", "a", "{\n c = k-a-b;\n sum = a-c;\n }", "c = k-a-b", "c", "k-a-b", "k-a-b", "k", "a", "b", "sum = a-c", "sum", "a-c", "a", "c", "{\n sum = a;\n }", "sum = a", "sum", "a", "{\n sum = k;\n }", "sum = k", "sum", "k", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }\n}", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum;\n\n if (a<=k) {\n if (b<=k-a) {\n c = k-a-b;\n sum = a-c;\n } else {\n sum = a;\n }\n } else {\n sum = k;\n }\n\n\tSystem.out.println(sum);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int sum; if (a<=k) { if (b<=k-a) { c = k-a-b; sum = a-c; } else { sum = a; } } else { sum = k; } System.out.println(sum); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 96, 14 ], [ 96, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 18, 20 ], [ 17, 21 ], [ 21, 22 ], [ 21, 23 ], [ 17, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 26, 29 ], [ 29, 30 ], [ 30, 31 ], [ 17, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 35, 36 ], [ 34, 37 ], [ 37, 38 ], [ 38, 39 ], [ 17, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 43, 44 ], [ 42, 45 ], [ 45, 46 ], [ 46, 47 ], [ 17, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 51, 52 ], [ 50, 53 ], [ 53, 54 ], [ 54, 55 ], [ 17, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 56, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 70, 72 ], [ 67, 73 ], [ 73, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 74, 79 ], [ 67, 80 ], [ 80, 81 ], [ 81, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 81, 86 ], [ 86, 87 ], [ 86, 88 ], [ 88, 89 ], [ 89, 90 ], [ 89, 91 ], [ 88, 92 ], [ 15, 93 ], [ 93, 94 ], [ 0, 95 ], [ 95, 96 ], [ 95, 97 ] ]
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.StringTokenizer;\n\npublic class Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.util.StringTokenizer;", "StringTokenizer", "java.util", "public class Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}\n}", "Main", "public static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}", "main", "{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}", "BufferedReader br = new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "StringTokenizer st = new StringTokenizer(br.readLine());", "st", "new StringTokenizer(br.readLine())", "int po = Integer.parseInt(st.nextToken());", "po", "Integer.parseInt(st.nextToken())", "Integer.parseInt", "Integer", "st.nextToken()", "st.nextToken", "st", "int z = Integer.parseInt(st.nextToken());", "z", "Integer.parseInt(st.nextToken())", "Integer.parseInt", "Integer", "st.nextToken()", "st.nextToken", "st", "int no = Integer.parseInt(st.nextToken());", "no", "Integer.parseInt(st.nextToken())", "Integer.parseInt", "Integer", "st.nextToken()", "st.nextToken", "st", "int K = Integer.parseInt(st.nextToken());", "K", "Integer.parseInt(st.nextToken())", "Integer.parseInt", "Integer", "st.nextToken()", "st.nextToken", "st", "if (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}", "K <= po", "K", "po", "{\n\t\t\tSystem.out.println(K);\n\t\t}", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}", "K <= po + z", "K", "po + z", "po", "z", "{\n\t\t\tSystem.out.println(po);\n\t\t}", "System.out.println(po)", "System.out.println", "System.out", "System", "System.out", "po", "{\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}", "System.out.println(po - (K - po - z))", "System.out.println", "System.out", "System", "System.out", "po - (K - po - z)", "po", "(K - po - z)", "K - po - z", "K", "po", "z", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tStringTokenizer st = new StringTokenizer(br.readLine());\n\t\tint po = Integer.parseInt(st.nextToken());\n\t\tint z = Integer.parseInt(st.nextToken());\n\t\tint no = Integer.parseInt(st.nextToken());\n\t\tint K = Integer.parseInt(st.nextToken());\n\t\tif (K <= po) {\n\t\t\tSystem.out.println(K);\n\t\t} else if (K <= po + z) {\n\t\t\tSystem.out.println(po);\n\t\t} else {\n\t\t\tSystem.out.println(po - (K - po - z));\n\t\t}\n\t}\n}", "Main" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine()); int po = Integer.parseInt(st.nextToken()); int z = Integer.parseInt(st.nextToken()); int no = Integer.parseInt(st.nextToken()); int K = Integer.parseInt(st.nextToken()); if (K <= po) { System.out.println(K); } else if (K <= po + z) { System.out.println(po); } else { System.out.println(po - (K - po - z)); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 17, 41, 13, 40, 17, 41, 13, 20, 17, 0, 18, 13, 17, 17, 0, 18, 13, 17, 17, 0, 18, 13, 17, 17, 11, 1, 41, 13, 17, 2, 2, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 40, 13, 40, 13, 40, 18, 13, 17, 11, 1, 41, 13, 17, 2, 2, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 40, 13, 40, 13, 40, 18, 13, 17, 11, 1, 41, 13, 17, 2, 2, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 40, 13, 40, 13, 40, 18, 13, 17, 41, 13, 2, 2, 2, 13, 18, 13, 17, 2, 13, 18, 13, 17, 2, 13, 18, 13, 17, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 167, 5 ], [ 167, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 40, 41 ], [ 8, 42 ], [ 42, 43 ], [ 42, 44 ], [ 8, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 8, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 8, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 8, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 70, 71 ], [ 70, 72 ], [ 61, 73 ], [ 73, 74 ], [ 74, 75 ], [ 61, 76 ], [ 77, 77 ], [ 77, 78 ], [ 78, 79 ], [ 77, 80 ], [ 80, 81 ], [ 77, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 8, 86 ], [ 86, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 86, 91 ], [ 91, 92 ], [ 92, 93 ], [ 92, 94 ], [ 91, 95 ], [ 95, 96 ], [ 95, 97 ], [ 86, 98 ], [ 98, 99 ], [ 99, 100 ], [ 86, 101 ], [ 102, 102 ], [ 102, 103 ], [ 103, 104 ], [ 102, 105 ], [ 105, 106 ], [ 102, 107 ], [ 107, 108 ], [ 108, 109 ], [ 108, 110 ], [ 8, 111 ], [ 111, 112 ], [ 112, 113 ], [ 113, 114 ], [ 113, 115 ], [ 111, 116 ], [ 116, 117 ], [ 117, 118 ], [ 117, 119 ], [ 116, 120 ], [ 120, 121 ], [ 120, 122 ], [ 111, 123 ], [ 123, 124 ], [ 124, 125 ], [ 111, 126 ], [ 127, 127 ], [ 127, 128 ], [ 128, 129 ], [ 127, 130 ], [ 130, 131 ], [ 127, 132 ], [ 132, 133 ], [ 133, 134 ], [ 133, 135 ], [ 8, 136 ], [ 136, 137 ], [ 136, 138 ], [ 139, 139 ], [ 139, 140 ], [ 140, 141 ], [ 140, 142 ], [ 142, 143 ], [ 142, 144 ], [ 139, 145 ], [ 145, 146 ], [ 145, 147 ], [ 147, 148 ], [ 147, 149 ], [ 139, 150 ], [ 150, 151 ], [ 150, 152 ], [ 152, 153 ], [ 152, 154 ], [ 8, 155 ], [ 155, 156 ], [ 156, 157 ], [ 157, 158 ], [ 157, 159 ], [ 155, 160 ], [ 8, 161 ], [ 161, 162 ], [ 162, 163 ], [ 6, 164 ], [ 164, 165 ], [ 0, 166 ], [ 166, 167 ], [ 166, 168 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }\n\t\t}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }\n\t\t}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A_cnt = sc.nextInt();", "A_cnt", "sc.nextInt()", "sc.nextInt", "sc", "int B_cnt = sc.nextInt();", "B_cnt", "sc.nextInt()", "sc.nextInt", "sc", "int C_cnt = sc.nextInt();", "C_cnt", "sc.nextInt()", "sc.nextInt", "sc", "int D_cnt = sc.nextInt();", "D_cnt", "sc.nextInt()", "sc.nextInt", "sc", "int A_1 = 1;", "A_1", "1", "int B_zero = 0;", "B_zero", "0", "int C_mainas = -1;", "C_mainas", "-1", "1", "int[] data = new int[3];", "data", "new int[3]", "3", "data[0] = 0", "data[0]", "data", "0", "0", "data[1] = 0", "data[1]", "data", "1", "0", "data[2] = 0", "data[2]", "data", "2", "0", "for(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "D_cnt > 0 && A_cnt > 0", "D_cnt > 0", "D_cnt", "0", "A_cnt > 0", "A_cnt", "0", "i++", "i++", "i", "{\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}", "{\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}", "D_cnt--", "D_cnt", "A_cnt--", "A_cnt", "data[0]++", "data[0]", "data", "0", "for(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "D_cnt > 0 && B_cnt > 0", "D_cnt > 0", "D_cnt", "0", "B_cnt > 0", "B_cnt", "0", "i++", "i++", "i", "{\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}", "{\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}", "D_cnt--", "D_cnt", "B_cnt--", "B_cnt", "data[1]++", "data[1]", "data", "1", "for(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "D_cnt > 0 && C_cnt > 0", "D_cnt > 0", "D_cnt", "0", "C_cnt > 0", "C_cnt", "0", "i++", "i++", "i", "{\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}", "{\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}", "D_cnt--", "D_cnt", "C_cnt--", "C_cnt", "data[2]++", "data[2]", "data", "2", "int Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];", "Total", "A_1 * data[0] + B_zero * data[1] + C_mainas * data[2]", "A_1 * data[0] + B_zero * data[1] + C_mainas * data[2]", "A_1 * data[0]", "A_1", "data[0]", "data", "0", "B_zero * data[1]", "B_zero", "data[1]", "data", "1", "C_mainas * data[2]", "C_mainas", "data[2]", "data", "2", "System.out.println(Total)", "System.out.println", "System.out", "System", "System.out", "Total", "sc.close()", "sc.close", "sc", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }\n\t\t}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A_cnt = sc.nextInt();\n\t\tint B_cnt = sc.nextInt();\n\t\tint C_cnt = sc.nextInt();\n\t\tint D_cnt = sc.nextInt();\n\t\t//初期値設定\n\t\tint A_1 = 1;\n\t\tint B_zero = 0;\n\t\tint C_mainas = -1;\n\n\t\t//入力されたデータを配列に代入しておく\n\t\tint[] data = new int[3];\n\t\tdata[0] = 0; //A\n\t\tdata[1] = 0; //B\n\t\tdata[2] = 0; //C\n\n\t\t//最大値演算\n\t\t//数値が大きい順にカウントしていく\n\t\t//D回文繰り返す。\n\t\tfor(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tA_cnt--;\n\t\t\tdata[0]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tB_cnt--;\n\t\t\tdata[1]++;\n\t\t}\n\t\tfor(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) {\n\t\t\tD_cnt--;\n\t\t\tC_cnt--;\n\t\t\tdata[2]++;\n\t\t}\n\t\tint Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2];\n\t\tSystem.out.println(Total);\n\t\tsc.close();\n\t\t }\n\t\t}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A_cnt = sc.nextInt(); int B_cnt = sc.nextInt(); int C_cnt = sc.nextInt(); int D_cnt = sc.nextInt(); //初期値設定 int A_1 = 1; int B_zero = 0; int C_mainas = -1; //入力されたデータを配列に代入しておく int[] data = new int[3]; data[0] = 0; //A data[1] = 0; //B data[2] = 0; //C //最大値演算 //数値が大きい順にカウントしていく //D回文繰り返す。 for(int i = 0;D_cnt > 0 && A_cnt > 0 ; i++) { D_cnt--; A_cnt--; data[0]++; } for(int i = 0;D_cnt > 0 && B_cnt > 0 ; i++) { D_cnt--; B_cnt--; data[1]++; } for(int i = 0;D_cnt > 0 && C_cnt > 0 ; i++) { D_cnt--; C_cnt--; data[2]++; } int Total = A_1 * data[0] + B_zero * data[1] + C_mainas * data[2]; System.out.println(Total); sc.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 4, 18, 13, 2, 13, 13, 17, 0, 13, 4, 18, 13, 2, 13, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 4, 18, 13, 2, 13, 13, 17, 4, 18, 13, 13, 23, 13, 23, 13, 23, 13, 6, 13, 41, 13, 41, 13, 20, 17, 41, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 23, 13, 12, 13, 30, 14, 2, 13, 40, 17, 30, 37, 20, 14, 2, 13, 13, 30, 0, 13, 17, 38, 5, 13, 30, 37, 20, 30, 0, 13, 4, 18, 13, 13, 14, 2, 13, 17, 30, 29, 40, 17, 29, 18, 13, 40, 13, 12, 13, 30, 41, 13, 4, 13, 42, 4, 13, 13, 30, 0, 13, 4, 13, 41, 13, 17, 14, 2, 13, 17, 30, 0, 13, 40, 17, 0, 13, 4, 13, 41, 13, 17, 42, 40, 4, 13, 13, 30, 14, 2, 2, 13, 17, 2, 13, 17, 30, 37, 20, 0, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 13, 29, 2, 13, 13, 12, 13, 30, 14, 2, 13, 17, 30, 29, 4, 18, 13, 13, 29, 4, 13, 13, 23, 13, 12, 13, 30, 29, 2, 2, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 40, 17, 23, 13, 6, 13, 12, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 325, 23 ], [ 325, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 29, 31 ], [ 26, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 34, 36 ], [ 26, 37 ], [ 37, 38 ], [ 37, 39 ], [ 26, 40 ], [ 40, 41 ], [ 40, 42 ], [ 26, 43 ], [ 43, 44 ], [ 43, 45 ], [ 26, 46 ], [ 46, 47 ], [ 47, 48 ], [ 46, 49 ], [ 46, 50 ], [ 46, 51 ], [ 26, 52 ], [ 52, 53 ], [ 53, 54 ], [ 24, 55 ], [ 55, 56 ], [ 325, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 59, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 65, 66 ], [ 61, 67 ], [ 67, 68 ], [ 67, 69 ], [ 69, 70 ], [ 70, 71 ], [ 61, 72 ], [ 72, 73 ], [ 72, 74 ], [ 74, 75 ], [ 75, 76 ], [ 61, 77 ], [ 77, 78 ], [ 77, 79 ], [ 79, 80 ], [ 80, 81 ], [ 61, 82 ], [ 82, 83 ], [ 82, 84 ], [ 61, 85 ], [ 85, 86 ], [ 85, 87 ], [ 87, 88 ], [ 88, 89 ], [ 87, 90 ], [ 87, 91 ], [ 61, 92 ], [ 92, 93 ], [ 92, 94 ], [ 94, 95 ], [ 95, 96 ], [ 94, 97 ], [ 97, 98 ], [ 97, 99 ], [ 94, 100 ], [ 61, 101 ], [ 101, 102 ], [ 101, 103 ], [ 103, 104 ], [ 104, 105 ], [ 103, 106 ], [ 106, 107 ], [ 106, 108 ], [ 103, 109 ], [ 61, 110 ], [ 110, 111 ], [ 110, 112 ], [ 112, 113 ], [ 113, 114 ], [ 112, 115 ], [ 112, 116 ], [ 61, 117 ], [ 117, 118 ], [ 117, 119 ], [ 119, 120 ], [ 120, 121 ], [ 119, 122 ], [ 122, 123 ], [ 122, 124 ], [ 119, 125 ], [ 61, 126 ], [ 126, 127 ], [ 127, 128 ], [ 126, 129 ], [ 59, 130 ], [ 130, 131 ], [ 59, 132 ], [ 132, 133 ], [ 59, 134 ], [ 134, 135 ], [ 325, 136 ], [ 136, 137 ], [ 136, 138 ], [ 138, 139 ], [ 136, 140 ], [ 140, 141 ], [ 140, 142 ], [ 136, 144 ], [ 144, 145 ], [ 136, 146 ], [ 146, 147 ], [ 136, 148 ], [ 148, 149 ], [ 136, 150 ], [ 150, 151 ], [ 150, 152 ], [ 152, 153 ], [ 153, 154 ], [ 154, 155 ], [ 154, 156 ], [ 153, 157 ], [ 150, 158 ], [ 158, 159 ], [ 136, 160 ], [ 160, 161 ], [ 160, 162 ], [ 162, 163 ], [ 163, 164 ], [ 164, 165 ], [ 164, 166 ], [ 166, 167 ], [ 163, 168 ], [ 168, 169 ], [ 169, 170 ], [ 162, 171 ], [ 171, 172 ], [ 172, 173 ], [ 172, 174 ], [ 171, 175 ], [ 175, 176 ], [ 176, 177 ], [ 176, 178 ], [ 175, 179 ], [ 179, 180 ], [ 180, 181 ], [ 180, 182 ], [ 182, 183 ], [ 183, 184 ], [ 179, 185 ], [ 185, 186 ], [ 186, 187 ], [ 186, 188 ], [ 188, 189 ], [ 189, 190 ], [ 188, 191 ], [ 175, 192 ], [ 192, 193 ], [ 193, 194 ], [ 193, 195 ], [ 192, 196 ], [ 196, 197 ], [ 197, 198 ], [ 198, 199 ], [ 162, 200 ], [ 200, 201 ], [ 201, 202 ], [ 201, 203 ], [ 203, 204 ], [ 136, 205 ], [ 205, 206 ], [ 205, 207 ], [ 207, 208 ], [ 208, 209 ], [ 208, 210 ], [ 210, 211 ], [ 207, 212 ], [ 212, 213 ], [ 213, 214 ], [ 213, 215 ], [ 212, 216 ], [ 216, 217 ], [ 217, 218 ], [ 217, 219 ], [ 219, 220 ], [ 207, 221 ], [ 221, 222 ], [ 221, 223 ], [ 207, 224 ], [ 224, 225 ], [ 225, 226 ], [ 225, 227 ], [ 224, 228 ], [ 228, 229 ], [ 229, 230 ], [ 229, 231 ], [ 231, 232 ], [ 228, 233 ], [ 233, 234 ], [ 233, 235 ], [ 235, 236 ], [ 207, 237 ], [ 237, 238 ], [ 237, 239 ], [ 207, 240 ], [ 240, 241 ], [ 241, 242 ], [ 242, 243 ], [ 242, 244 ], [ 240, 245 ], [ 245, 246 ], [ 246, 247 ], [ 247, 248 ], [ 248, 249 ], [ 248, 250 ], [ 247, 251 ], [ 251, 252 ], [ 251, 253 ], [ 246, 254 ], [ 254, 255 ], [ 255, 256 ], [ 245, 257 ], [ 257, 258 ], [ 257, 259 ], [ 245, 260 ], [ 260, 261 ], [ 260, 262 ], [ 262, 263 ], [ 262, 264 ], [ 245, 265 ], [ 265, 266 ], [ 265, 267 ], [ 267, 268 ], [ 207, 269 ], [ 269, 270 ], [ 270, 271 ], [ 270, 272 ], [ 136, 273 ], [ 273, 274 ], [ 273, 275 ], [ 275, 276 ], [ 276, 277 ], [ 277, 278 ], [ 277, 279 ], [ 276, 280 ], [ 280, 281 ], [ 281, 282 ], [ 282, 283 ], [ 283, 284 ], [ 282, 285 ], [ 275, 286 ], [ 286, 287 ], [ 287, 288 ], [ 287, 289 ], [ 273, 290 ], [ 290, 291 ], [ 136, 292 ], [ 292, 293 ], [ 292, 294 ], [ 294, 295 ], [ 295, 296 ], [ 299, 297 ], [ 309, 298 ], [ 306, 299 ], [ 299, 300 ], [ 300, 301 ], [ 300, 302 ], [ 299, 303 ], [ 303, 304 ], [ 303, 305 ], [ 306, 306 ], [ 306, 307 ], [ 306, 308 ], [ 309, 309 ], [ 309, 310 ], [ 309, 311 ], [ 299, 312 ], [ 312, 313 ], [ 312, 314 ], [ 314, 315 ], [ 292, 316 ], [ 316, 317 ], [ 136, 318 ], [ 318, 319 ], [ 318, 320 ], [ 320, 321 ], [ 320, 322 ], [ 322, 323 ], [ 0, 324 ], [ 324, 325 ], [ 324, 326 ] ]
[ "import java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.PrintWriter;\nimport java.util.InputMismatchException;\nimport java.io.IOException;\nimport java.io.InputStream;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n */\npublic class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }\n\n }\n\n static class FastReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n private FastReader.SpaceCharFilter filter;\n\n public FastReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }\n\n public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }\n\n }\n}\n", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.util.InputMismatchException;", "InputMismatchException", "java.util", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }\n\n }\n\n static class FastReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n private FastReader.SpaceCharFilter filter;\n\n public FastReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }\n\n public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }\n\n }\n}", "Main", "public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "FastReader in = new FastReader(inputStream);", "in", "new FastReader(inputStream)", "PrintWriter out = new PrintWriter(outputStream);", "out", "new PrintWriter(outputStream)", "BEasyLinearProgramming solver = new BEasyLinearProgramming();", "solver", "new BEasyLinearProgramming()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class BEasyLinearProgramming {\n public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }\n\n }", "BEasyLinearProgramming", "public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }", "solve", "{\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }", "int a = s.nextInt();", "a", "s.nextInt()", "s.nextInt", "s", "int b = s.nextInt();", "b", "s.nextInt()", "s.nextInt", "s", "int c = s.nextInt();", "c", "s.nextInt()", "s.nextInt", "s", "int k = s.nextInt();", "k", "s.nextInt()", "s.nextInt", "s", "int ans = 0;", "ans", "0", "ans += Math.min(a, k)", "ans", "Math.min(a, k)", "Math.min", "Math", "a", "k", "k = Math.max(k - a, 0)", "k", "Math.max(k - a, 0)", "Math.max", "Math", "k - a", "k", "a", "0", "k = Math.max(k - b, 0)", "k", "Math.max(k - b, 0)", "Math.max", "Math", "k - b", "k", "b", "0", "ans -= Math.min(c, k)", "ans", "Math.min(c, k)", "Math.min", "Math", "c", "k", "k = Math.max(k - c, 0)", "k", "Math.max(k - c, 0)", "Math.max", "Math", "k - c", "k", "c", "0", "out.println(ans)", "out.println", "out", "ans", "int testNumber", "testNumber", "FastReader s", "s", "PrintWriter out", "out", "static class FastReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n private FastReader.SpaceCharFilter filter;\n\n public FastReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }\n\n public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }\n\n }", "FastReader", "private InputStream stream;", "stream", "private byte[] buf = new byte[1024];", "buf", "new byte[1024]", "1024", "private int curChar;", "curChar", "private int numChars;", "numChars", "private FastReader.SpaceCharFilter filter;", "filter", "public FastReader(InputStream stream) {\n this.stream = stream;\n }", "FastReader", "{\n this.stream = stream;\n }", "this.stream = stream", "this.stream", "this", "this.stream", "stream", "InputStream stream", "stream", "public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }", "read", "{\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }", "if (numChars == -1) {\n throw new InputMismatchException();\n }", "numChars == -1", "numChars", "-1", "1", "{\n throw new InputMismatchException();\n }", "throw new InputMismatchException();", "new InputMismatchException()", "if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }", "curChar >= numChars", "curChar", "numChars", "{\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }", "curChar = 0", "curChar", "0", "try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }", "catch (IOException e) {\n throw new InputMismatchException();\n }", "IOException e", "{\n throw new InputMismatchException();\n }", "throw new InputMismatchException();", "new InputMismatchException()", "{\n numChars = stream.read(buf);\n }", "numChars = stream.read(buf)", "numChars", "stream.read(buf)", "stream.read", "stream", "buf", "if (numChars <= 0) {\n return -1;\n }", "numChars <= 0", "numChars", "0", "{\n return -1;\n }", "return -1;", "-1", "1", "return buf[curChar++];", "buf[curChar++]", "buf", "curChar++", "curChar", "public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }", "nextInt", "{\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }", "int c = read();", "c", "read()", "read", "while (isSpaceChar(c)) {\n c = read();\n }", "isSpaceChar(c)", "isSpaceChar", "c", "{\n c = read();\n }", "c = read()", "c", "read()", "read", "int sgn = 1;", "sgn", "1", "if (c == '-') {\n sgn = -1;\n c = read();\n }", "c == '-'", "c", "'-'", "{\n sgn = -1;\n c = read();\n }", "sgn = -1", "sgn", "-1", "1", "c = read()", "c", "read()", "read", "int res = 0;", "res", "0", "do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));", "!isSpaceChar(c)", "isSpaceChar(c)", "isSpaceChar", "c", "{\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n }", "if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }", "c < '0' || c > '9'", "c < '0'", "c", "'0'", "c > '9'", "c", "'9'", "{\n throw new InputMismatchException();\n }", "throw new InputMismatchException();", "new InputMismatchException()", "res *= 10", "res", "10", "res += c - '0'", "res", "c - '0'", "c", "'0'", "c = read()", "c", "read()", "read", "return res * sgn;", "res * sgn", "res", "sgn", "public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }", "isSpaceChar", "{\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }", "if (filter != null) {\n return filter.isSpaceChar(c);\n }", "filter != null", "filter", "null", "{\n return filter.isSpaceChar(c);\n }", "return filter.isSpaceChar(c);", "filter.isSpaceChar(c)", "filter.isSpaceChar", "filter", "c", "return isWhitespace(c);", "isWhitespace(c)", "isWhitespace", "c", "int c", "c", "public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "isWhitespace", "{\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == '\\t'", "c == '\\r'", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == ' '", "c", "' '", "c == '\\n'", "c", "'\\n'", "c == '\\r'", "c", "'\\r'", "c == '\\t'", "c", "'\\t'", "c == -1", "c", "-1", "1", "int c", "c", "public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }", "SpaceCharFilter", "public boolean isSpaceChar(int ch);", "isSpaceChar", "int ch", "ch", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }\n\n }\n\n static class FastReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n private FastReader.SpaceCharFilter filter;\n\n public FastReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }\n\n public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }\n\n }\n}", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n FastReader in = new FastReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, FastReader s, PrintWriter out) {\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n\n int ans = 0;\n ans += Math.min(a, k);\n\n k = Math.max(k - a, 0);\n k = Math.max(k - b, 0);\n\n ans -= Math.min(c, k);\n k = Math.max(k - c, 0);\n out.println(ans);\n }\n\n }\n\n static class FastReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n private FastReader.SpaceCharFilter filter;\n\n public FastReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1) {\n throw new InputMismatchException();\n }\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0) {\n return -1;\n }\n }\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n while (isSpaceChar(c)) {\n c = read();\n }\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n int res = 0;\n do {\n if (c < '0' || c > '9') {\n throw new InputMismatchException();\n }\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n if (filter != null) {\n return filter.isSpaceChar(c);\n }\n return isWhitespace(c);\n }\n\n public static boolean isWhitespace(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n public interface SpaceCharFilter {\n public boolean isSpaceChar(int ch);\n\n }\n\n }\n}", "Main" ]
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.PrintWriter; import java.util.InputMismatchException; import java.io.IOException; import java.io.InputStream; /** * Built using CHelper plug-in * Actual solution is at the top */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; FastReader in = new FastReader(inputStream); PrintWriter out = new PrintWriter(outputStream); BEasyLinearProgramming solver = new BEasyLinearProgramming(); solver.solve(1, in, out); out.close(); } static class BEasyLinearProgramming { public void solve(int testNumber, FastReader s, PrintWriter out) { int a = s.nextInt(); int b = s.nextInt(); int c = s.nextInt(); int k = s.nextInt(); int ans = 0; ans += Math.min(a, k); k = Math.max(k - a, 0); k = Math.max(k - b, 0); ans -= Math.min(c, k); k = Math.max(k - c, 0); out.println(ans); } } static class FastReader { private InputStream stream; private byte[] buf = new byte[1024]; private int curChar; private int numChars; private FastReader.SpaceCharFilter filter; public FastReader(InputStream stream) { this.stream = stream; } public int read() { if (numChars == -1) { throw new InputMismatchException(); } if (curChar >= numChars) { curChar = 0; try { numChars = stream.read(buf); } catch (IOException e) { throw new InputMismatchException(); } if (numChars <= 0) { return -1; } } return buf[curChar++]; } public int nextInt() { int c = read(); while (isSpaceChar(c)) { c = read(); } int sgn = 1; if (c == '-') { sgn = -1; c = read(); } int res = 0; do { if (c < '0' || c > '9') { throw new InputMismatchException(); } res *= 10; res += c - '0'; c = read(); } while (!isSpaceChar(c)); return res * sgn; } public boolean isSpaceChar(int c) { if (filter != null) { return filter.isSpaceChar(c); } return isWhitespace(c); } public static boolean isWhitespace(int c) { return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1; } public interface SpaceCharFilter { public boolean isSpaceChar(int ch); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 0, 13, 13, 29, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 0, 13, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 82, 5 ], [ 82, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 40, 45 ], [ 45, 46 ], [ 45, 47 ], [ 39, 48 ], [ 35, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 8, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 56, 57 ], [ 56, 58 ], [ 53, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 60, 65 ], [ 65, 66 ], [ 65, 67 ], [ 68, 68 ], [ 68, 69 ], [ 68, 70 ], [ 68, 71 ], [ 53, 72 ], [ 72, 73 ], [ 73, 74 ], [ 74, 75 ], [ 75, 76 ], [ 75, 77 ], [ 73, 78 ], [ 6, 79 ], [ 79, 80 ], [ 0, 81 ], [ 81, 82 ], [ 81, 83 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main (String[] args) {\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main (String[] args) {\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}\n}", "Main", "public static void main (String[] args) {\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}", "main", "{\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int total = 0;", "total", "0", "if(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}", "A >= K", "A", "K", "{ //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}", "System.out.println(total=K)", "System.out.println", "System.out", "System", "System.out", "total=K", "total", "K", "return;", "{ //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}", "total = A", "total", "A", "if(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}", "B < K-A", "B", "K-A", "K", "A", "{ //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}", "System.out.println(total-= K-A-B)", "System.out.println", "System.out", "System", "System.out", "total-= K-A-B", "total", "K-A-B", "K-A-B", "K", "A", "B", "{ //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}", "System.out.println(total)", "System.out.println", "System.out", "System", "System.out", "total", "String[] args", "args", "public class Main {\n\tpublic static void main (String[] args) {\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}\n}", "public class Main {\n\tpublic static void main (String[] args) {\n\n//\tパターン1(Aから順番に使って足していく)\n//\t変数を読み込む\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint total = 0; //合計を入れる変数\n\n//\tAから順に、合計K枚になるまで足していく\n\t\tif(A >= K) { //A>KならKの枚数を表示で終了\n\t\t\tSystem.out.println(total=K);\n\t\t\treturn;\n\t\t}\n\t\telse { //A<Kの場合は続く\n\t\t\ttotal = A;\n\t\t}\n\n//\tBがK-Aより多いか少ないかで判断\n\t\tif(B < K-A) { //B<=K-AならK-A-B枚分-1をする\n\t\t\tSystem.out.println(total-= K-A-B);\n\t\t}\n\t\telse { //B>K-Aならそのまま表示\n\t\t\tSystem.out.println(total);\n\t\t}\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main (String[] args) { // パターン1(Aから順番に使って足していく) // 変数を読み込む Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int total = 0; //合計を入れる変数 // Aから順に、合計K枚になるまで足していく if(A >= K) { //A>KならKの枚数を表示で終了 System.out.println(total=K); return; } else { //A<Kの場合は続く total = A; } // BがK-Aより多いか少ないかで判断 if(B < K-A) { //B<=K-AならK-A-B枚分-1をする System.out.println(total-= K-A-B); } else { //B>K-Aならそのまま表示 System.out.println(total); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 4, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 17, 14, 2, 13, 17, 30, 14, 2, 2, 13, 13, 17, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 17, 30, 14, 2, 2, 13, 13, 17, 30, 0, 13, 13, 30, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 17, 30, 0, 13, 2, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 135, 11 ], [ 135, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 15, 17 ], [ 14, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 22, 23 ], [ 23, 24 ], [ 20, 25 ], [ 14, 26 ], [ 26, 27 ], [ 26, 28 ], [ 28, 29 ], [ 29, 30 ], [ 28, 31 ], [ 31, 32 ], [ 31, 33 ], [ 14, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 37, 38 ], [ 36, 39 ], [ 39, 40 ], [ 39, 41 ], [ 14, 42 ], [ 42, 43 ], [ 42, 44 ], [ 44, 45 ], [ 45, 46 ], [ 44, 47 ], [ 47, 48 ], [ 47, 49 ], [ 14, 50 ], [ 50, 51 ], [ 50, 52 ], [ 52, 53 ], [ 53, 54 ], [ 52, 55 ], [ 55, 56 ], [ 55, 57 ], [ 14, 58 ], [ 58, 59 ], [ 58, 60 ], [ 14, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 67, 71 ], [ 66, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 72, 76 ], [ 76, 77 ], [ 76, 78 ], [ 66, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 79, 83 ], [ 83, 84 ], [ 83, 85 ], [ 14, 86 ], [ 86, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 87, 91 ], [ 91, 92 ], [ 91, 93 ], [ 86, 94 ], [ 94, 95 ], [ 95, 96 ], [ 96, 97 ], [ 97, 98 ], [ 97, 99 ], [ 96, 100 ], [ 95, 101 ], [ 101, 102 ], [ 102, 103 ], [ 102, 104 ], [ 95, 105 ], [ 105, 106 ], [ 106, 107 ], [ 106, 108 ], [ 14, 109 ], [ 109, 110 ], [ 110, 111 ], [ 111, 112 ], [ 111, 113 ], [ 110, 114 ], [ 114, 115 ], [ 114, 116 ], [ 109, 117 ], [ 117, 118 ], [ 118, 119 ], [ 118, 120 ], [ 120, 121 ], [ 120, 122 ], [ 122, 123 ], [ 122, 124 ], [ 124, 125 ], [ 14, 126 ], [ 126, 127 ], [ 127, 128 ], [ 128, 129 ], [ 128, 130 ], [ 126, 131 ], [ 12, 132 ], [ 132, 133 ], [ 0, 134 ], [ 134, 135 ], [ 134, 136 ] ]
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\npublic class Main {\n public static void main(String args[]) throws IOException {\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "public class Main {\n public static void main(String args[]) throws IOException {\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }\n}", "Main", "public static void main(String args[]) throws IOException {\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }", "main", "{\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }", "BufferedReader br = new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "String[] strArray = br.readLine().split(\" \");", "strArray", "br.readLine().split(\" \")", "br.readLine().split", "br.readLine()", "br.readLine", "br", "\" \"", "int A = Integer.parseInt(strArray[0]);", "A", "Integer.parseInt(strArray[0])", "Integer.parseInt", "Integer", "strArray[0]", "strArray", "0", "int B = Integer.parseInt(strArray[1]);", "B", "Integer.parseInt(strArray[1])", "Integer.parseInt", "Integer", "strArray[1]", "strArray", "1", "int C = Integer.parseInt(strArray[2]);", "C", "Integer.parseInt(strArray[2])", "Integer.parseInt", "Integer", "strArray[2]", "strArray", "2", "int K = Integer.parseInt(strArray[3]);", "K", "Integer.parseInt(strArray[3])", "Integer.parseInt", "Integer", "strArray[3]", "strArray", "3", "int sum = 0;", "sum", "0", "if (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}", "A > 0", "A", "0", "{\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}", "if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }", "K - A > 0", "K - A", "K", "A", "0", "{\n\t\tsum += A;\n\t\tK -= A;\n\t }", "sum += A", "sum", "A", "K -= A", "K", "A", "{\n\t\tsum = K;\n\t\tK = 0;\n\t }", "sum = K", "sum", "K", "K = 0", "K", "0", "if (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}", "K > 0 && B > 0", "K > 0", "K", "0", "B > 0", "B", "0", "{\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}", "if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }", "K - B > 0", "K - B", "K", "B", "0", "{\n\t\tK -= B;\n\t }", "K -= B", "K", "B", "{\n\t\tK = 0;\n\t }", "K = 0", "K", "0", "if (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}", "K > 0 && C > 0", "K > 0", "K", "0", "C > 0", "C", "0", "{\n\t sum = sum + (K * -1);\n\t}", "sum = sum + (K * -1)", "sum", "sum + (K * -1)", "sum", "(K * -1)", "K", "-1", "1", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String args[]", "args", "public class Main {\n public static void main(String args[]) throws IOException {\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }\n}", "public class Main {\n public static void main(String args[]) throws IOException {\n\n\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\tString[] strArray = br.readLine().split(\" \");\n\tint A = Integer.parseInt(strArray[0]);\n\tint B = Integer.parseInt(strArray[1]);\n\tint C = Integer.parseInt(strArray[2]);\n\tint K = Integer.parseInt(strArray[3]);\n\tint sum = 0;\n\n\tif (A > 0) {\n\t if (K - A > 0) {\n\t\tsum += A;\n\t\tK -= A;\n\t } else {\n\t\tsum = K;\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && B > 0) {\n\t if (K - B > 0) {\n\t\tK -= B;\n\t } else {\n\t\tK = 0;\n\t }\n\t}\n\n\tif (K > 0 && C > 0) {\n\t sum = sum + (K * -1);\n\t}\n\n\tSystem.out.println(sum);\n }\n}", "Main" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String args[]) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String[] strArray = br.readLine().split(" "); int A = Integer.parseInt(strArray[0]); int B = Integer.parseInt(strArray[1]); int C = Integer.parseInt(strArray[2]); int K = Integer.parseInt(strArray[3]); int sum = 0; if (A > 0) { if (K - A > 0) { sum += A; K -= A; } else { sum = K; K = 0; } } if (K > 0 && B > 0) { if (K - B > 0) { K -= B; } else { K = 0; } } if (K > 0 && C > 0) { sum = sum + (K * -1); } System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 39, 17, 17, 40, 17, 41, 13, 39, 13, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 14, 2, 18, 13, 13, 13, 30, 0, 13, 2, 13, 2, 18, 13, 13, 18, 13, 13, 0, 13, 2, 13, 18, 13, 13, 30, 0, 13, 2, 13, 2, 18, 13, 13, 13, 3, 4, 18, 18, 13, 13, 13, 29, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 107, 5 ], [ 107, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 37, 39 ], [ 37, 40 ], [ 40, 41 ], [ 8, 42 ], [ 42, 43 ], [ 42, 44 ], [ 44, 45 ], [ 44, 46 ], [ 44, 47 ], [ 8, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 48, 53 ], [ 53, 54 ], [ 53, 55 ], [ 48, 56 ], [ 56, 57 ], [ 57, 58 ], [ 48, 59 ], [ 60, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 61, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 70, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 72, 76 ], [ 76, 77 ], [ 76, 78 ], [ 67, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 61, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 89, 90 ], [ 89, 91 ], [ 91, 92 ], [ 92, 93 ], [ 92, 94 ], [ 91, 95 ], [ 86, 96 ], [ 8, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 97, 102 ], [ 8, 103 ], [ 6, 104 ], [ 104, 105 ], [ 0, 106 ], [ 106, 107 ], [ 106, 108 ] ]
[ "import java.util.*;\n\n\npublic class Main{\n public static void main(String[] args) throws Exception{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n } \n}", "import java.util.*;", "util.*", "java", "public class Main{\n public static void main(String[] args) throws Exception{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n } \n}", "Main", "public static void main(String[] args) throws Exception{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n }", "main", "{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int sum_number = 0;", "sum_number", "0", "int[] numbers = {1,0,-1};", "numbers", "{1,0,-1}", "1", "0", "-1", "1", "int[] cards = {a,b,c};", "cards", "{a,b,c}", "a", "b", "c", "for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i<=2", "i", "2", "i++", "i++", "i", "{\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }", "{\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }", "if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }", "cards[i]<=k", "cards[i]", "cards", "i", "k", "{\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }", "sum_number = sum_number + (numbers[i] * cards[i])", "sum_number", "sum_number + (numbers[i] * cards[i])", "sum_number", "(numbers[i] * cards[i])", "numbers[i]", "numbers", "i", "cards[i]", "cards", "i", "k = k - cards[i]", "k", "k - cards[i]", "k", "cards[i]", "cards", "i", "{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }", "sum_number = sum_number + (numbers[i] * k)", "sum_number", "sum_number + (numbers[i] * k)", "sum_number", "(numbers[i] * k)", "numbers[i]", "numbers", "i", "k", "break;", "System.out.println(sum_number)", "System.out.println", "System.out", "System", "System.out", "sum_number", "return;", "String[] args", "args", "public class Main{\n public static void main(String[] args) throws Exception{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n } \n}", "public class Main{\n public static void main(String[] args) throws Exception{\n \n Scanner sc = new Scanner(System.in);\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();//3\n int sum_number = 0;\n\n int[] numbers = {1,0,-1};\n int[] cards = {a,b,c}; //2,1,1\n\n for(int i = 0; i<=2; i++){\n if(cards[i]<=k){\n sum_number = sum_number + (numbers[i] * cards[i]);\n k = k - cards[i];\n\n }else{\n sum_number = sum_number + (numbers[i] * k);\n break;\n }\n }\n System.out.println(sum_number);\n return;\n } \n}", "Main" ]
import java.util.*; public class Main{ public static void main(String[] args) throws Exception{ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt();//3 int sum_number = 0; int[] numbers = {1,0,-1}; int[] cards = {a,b,c}; //2,1,1 for(int i = 0; i<=2; i++){ if(cards[i]<=k){ sum_number = sum_number + (numbers[i] * cards[i]); k = k - cards[i]; }else{ sum_number = sum_number + (numbers[i] * k); break; } } System.out.println(sum_number); return; } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 84, 5 ], [ 84, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 44, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 49, 54 ], [ 44, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 55, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 55, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 69, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 76, 78 ], [ 78, 79 ], [ 78, 80 ], [ 6, 81 ], [ 81, 82 ], [ 0, 83 ], [ 83, 84 ], [ 83, 85 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }\n}", "Main", "public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }", "main", "{\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int A = Integer.parseInt(scan.next());", "A", "Integer.parseInt(scan.next())", "Integer.parseInt", "Integer", "scan.next()", "scan.next", "scan", "int B = Integer.parseInt(scan.next());", "B", "Integer.parseInt(scan.next())", "Integer.parseInt", "Integer", "scan.next()", "scan.next", "scan", "int C = Integer.parseInt(scan.next());", "C", "Integer.parseInt(scan.next())", "Integer.parseInt", "Integer", "scan.next()", "scan.next", "scan", "int K = Integer.parseInt(scan.next());", "K", "Integer.parseInt(scan.next())", "Integer.parseInt", "Integer", "scan.next()", "scan.next", "scan", "if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }", "A >= K", "A", "K", "{\n System.out.println(K);\n }", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }", "(A + B) >= K", "(A + B)", "A", "B", "K", "{\n System.out.println(A);\n }", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "{\n System.out.println(A - (K - (A + B)));\n }", "System.out.println(A - (K - (A + B)))", "System.out.println", "System.out", "System", "System.out", "A - (K - (A + B))", "A", "(K - (A + B))", "K", "(A + B)", "A", "B", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int A = Integer.parseInt(scan.next());\n int B = Integer.parseInt(scan.next());\n int C = Integer.parseInt(scan.next());\n int K = Integer.parseInt(scan.next());\n\n if (A >= K) {\n System.out.println(K);\n } else if ((A + B) >= K) {\n System.out.println(A);\n } else {\n System.out.println(A - (K - (A + B)));\n }\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int A = Integer.parseInt(scan.next()); int B = Integer.parseInt(scan.next()); int C = Integer.parseInt(scan.next()); int K = Integer.parseInt(scan.next()); if (A >= K) { System.out.println(K); } else if ((A + B) >= K) { System.out.println(A); } else { System.out.println(A - (K - (A + B))); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 41, 13, 41, 13, 41, 13, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 13, 14, 2, 13, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 90, 5 ], [ 90, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 8, 14 ], [ 14, 15 ], [ 8, 16 ], [ 16, 17 ], [ 8, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 8, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 8, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 8, 40 ], [ 40, 41 ], [ 41, 42 ], [ 41, 43 ], [ 40, 44 ], [ 44, 45 ], [ 45, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 45, 50 ], [ 40, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 54, 55 ], [ 54, 56 ], [ 51, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 58, 63 ], [ 63, 64 ], [ 63, 65 ], [ 51, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 70, 70 ], [ 70, 71 ], [ 70, 72 ], [ 70, 73 ], [ 66, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 75, 80 ], [ 80, 81 ], [ 80, 82 ], [ 82, 83 ], [ 82, 84 ], [ 84, 85 ], [ 84, 86 ], [ 6, 87 ], [ 87, 88 ], [ 0, 89 ], [ 89, 90 ], [ 89, 91 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }\n}", "Main", "public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }", "main", "{\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }", "final Scanner scanner = new Scanner(System.in);", "scanner", "new Scanner(System.in)", "int a", "a", "b", "b", "c", "c", "k;", "k", "a = scanner.nextInt()", "a", "scanner.nextInt()", "scanner.nextInt", "scanner", "b = scanner.nextInt()", "b", "scanner.nextInt()", "scanner.nextInt", "scanner", "c = scanner.nextInt()", "c", "scanner.nextInt()", "scanner.nextInt", "scanner", "k = scanner.nextInt()", "k", "scanner.nextInt()", "scanner.nextInt", "scanner", "if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }", "k <= a", "k", "a", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }", "k <= a+b", "k", "a+b", "a", "b", "{\n System.out.println(k-b);\n }", "System.out.println(k-b)", "System.out.println", "System.out", "System", "System.out", "k-b", "k", "b", "if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }", "k <= a+b+c", "k", "a+b+c", "a+b+c", "a", "b", "c", "{\n System.out.println(a-(k-(a+b)));\n }", "System.out.println(a-(k-(a+b)))", "System.out.println", "System.out", "System", "System.out", "a-(k-(a+b))", "a", "(k-(a+b))", "k", "(a+b)", "a", "b", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }\n}", "public class Main {\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n int a, b, c, k;\n\n a = scanner.nextInt();\n b = scanner.nextInt();\n c = scanner.nextInt();\n k = scanner.nextInt();\n\n if(k <= a) {\n System.out.println(k);\n }\n else if(k <= a+b) {\n System.out.println(k-b);\n }\n else if (k <= a+b+c) {\n System.out.println(a-(k-(a+b)));\n }\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { final Scanner scanner = new Scanner(System.in); int a, b, c, k; a = scanner.nextInt(); b = scanner.nextInt(); c = scanner.nextInt(); k = scanner.nextInt(); if(k <= a) { System.out.println(k); } else if(k <= a+b) { System.out.println(k-b); } else if (k <= a+b+c) { System.out.println(a-(k-(a+b))); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 13, 13, 2, 2, 13, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 79, 5 ], [ 79, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 44, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 48, 52 ], [ 43, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 43, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 60, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 64, 66 ], [ 8, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 67, 72 ], [ 8, 73 ], [ 73, 74 ], [ 74, 75 ], [ 6, 76 ], [ 76, 77 ], [ 0, 78 ], [ 78, 79 ], [ 78, 80 ] ]
[ "import java.util.*;\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}\n}", "Main", "public static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "long a = sc.nextLong();", "a", "sc.nextLong()", "sc.nextLong", "sc", "long b = sc.nextLong();", "b", "sc.nextLong()", "sc.nextLong", "sc", "long c = sc.nextLong();", "c", "sc.nextLong()", "sc.nextLong", "sc", "long k = sc.nextLong();", "k", "sc.nextLong()", "sc.nextLong", "sc", "long sum = 0;", "sum", "0", "if (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}", "a >= k", "a", "k", "{\n\t\t\tsum = k;\n\t\t}", "sum = k", "sum", "k", "if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}", "a < k && a + b >= k", "a < k", "a", "k", "a + b >= k", "a + b", "a", "b", "k", "{\n\t\t\tsum = a;\n\t\t}", "sum = a", "sum", "a", "{\n\t\t\tsum = a - (k - (a + b));\n\t\t}", "sum = a - (k - (a + b))", "sum", "a - (k - (a + b))", "a", "(k - (a + b))", "k", "(a + b)", "a", "b", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "sc.close()", "sc.close", "sc", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t// 文字列の入力\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\n\t\tlong sum = 0;\n\t\tif (a >= k) {\n\t\t\tsum = k;\n\t\t} else if (a < k && a + b >= k) {\n\t\t\tsum = a;\n\t\t} else {\n\t\t\tsum = a - (k - (a + b));\n\t\t}\n\n\t\t// 出力\n\t\tSystem.out.println(sum);\n\t\tsc.close();\n\t}\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); // 文字列の入力 long a = sc.nextLong(); long b = sc.nextLong(); long c = sc.nextLong(); long k = sc.nextLong(); long sum = 0; if (a >= k) { sum = k; } else if (a < k && a + b >= k) { sum = a; } else { sum = a - (k - (a + b)); } // 出力 System.out.println(sum); sc.close(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 13, 2, 13, 13, 30, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 88, 5 ], [ 88, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 47, 49 ], [ 44, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 56, 61 ], [ 51, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 63, 68 ], [ 44, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 70, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 77, 81 ], [ 8, 82 ], [ 82, 83 ], [ 83, 84 ], [ 6, 85 ], [ 85, 86 ], [ 0, 87 ], [ 87, 88 ], [ 87, 89 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(final String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(final String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }\n}", "Main", "public static void main(final String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = Integer.parseInt(sc.next());", "a", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int b = Integer.parseInt(sc.next());", "b", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int c = Integer.parseInt(sc.next());", "c", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int k = Integer.parseInt(sc.next());", "k", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }", "k <= a + b", "k", "a + b", "a", "b", "{\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n }", "if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }", "k >= a", "k", "a", "{\n System.out.println(a);\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "{\n System.out.println(a - (k - a - b));\n }", "System.out.println(a - (k - a - b))", "System.out.println", "System.out", "System", "System.out", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "sc.close()", "sc.close", "sc", "final String[] args", "args", "public class Main {\n public static void main(final String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }\n}", "public class Main {\n public static void main(final String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n\n if (k <= a + b) {\n if (k >= a) {\n System.out.println(a);\n } else {\n System.out.println(k);\n }\n } else {\n System.out.println(a - (k - a - b));\n }\n\n sc.close();\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(final String[] args) { Scanner sc = new Scanner(System.in); int a = Integer.parseInt(sc.next()); int b = Integer.parseInt(sc.next()); int c = Integer.parseInt(sc.next()); int k = Integer.parseInt(sc.next()); if (k <= a + b) { if (k >= a) { System.out.println(a); } else { System.out.println(k); } } else { System.out.println(a - (k - a - b)); } sc.close(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 14, 2, 13, 2, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 2, 2, 13, 13, 13, 1, 40, 13, 30, 30, 40, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 106, 5 ], [ 106, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 40, 45 ], [ 45, 46 ], [ 45, 47 ], [ 40, 48 ], [ 48, 49 ], [ 49, 50 ], [ 40, 51 ], [ 52, 52 ], [ 52, 53 ], [ 53, 54 ], [ 35, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 56, 61 ], [ 61, 62 ], [ 61, 63 ], [ 56, 64 ], [ 64, 65 ], [ 65, 66 ], [ 56, 67 ], [ 68, 68 ], [ 68, 69 ], [ 69, 70 ], [ 8, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 74, 75 ], [ 74, 76 ], [ 71, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 78, 83 ], [ 83, 84 ], [ 83, 85 ], [ 86, 86 ], [ 86, 87 ], [ 86, 88 ], [ 86, 89 ], [ 78, 90 ], [ 90, 91 ], [ 91, 92 ], [ 78, 93 ], [ 94, 94 ], [ 94, 95 ], [ 95, 96 ], [ 8, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 97, 102 ], [ 6, 103 ], [ 103, 104 ], [ 0, 105 ], [ 105, 106 ], [ 105, 107 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}", "main", "{\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int A = scan.nextInt();", "A", "scan.nextInt()", "scan.nextInt", "scan", "int B = scan.nextInt();", "B", "scan.nextInt()", "scan.nextInt", "scan", "int C = scan.nextInt();", "C", "scan.nextInt()", "scan.nextInt", "scan", "int K = scan.nextInt();", "K", "scan.nextInt()", "scan.nextInt", "scan", "int ans = 0;", "ans", "0", "if(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}", "A < K", "A", "K", "{\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}", "for(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}", "int i=0;", "int i=0;", "i", "0", "i<A", "i", "A", "i++", "i++", "i", "{\n\t\t\t\tans++;\n\t\t\t}", "{\n\t\t\t\tans++;\n\t\t\t}", "ans++", "ans", "{\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}", "for(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}", "int j=0;", "int j=0;", "j", "0", "j<K", "j", "K", "j++", "j++", "j", "{\n\t\t\t\tans++;\n\t\t\t}", "{\n\t\t\t\tans++;\n\t\t\t}", "ans++", "ans", "if(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}", "B < K-A", "B", "K-A", "K", "A", "{\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}", "for(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}", "int i=0;", "int i=0;", "i", "0", "i<K-A-B", "i", "K-A-B", "K-A-B", "K", "A", "B", "i++", "i++", "i", "{\n\t\t\t\tans--;\n\t\t\t}", "{\n\t\t\t\tans--;\n\t\t\t}", "ans--", "ans", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}\n\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\t\t\n\t\tif(A < K) {\n\t\t\tfor(int i=0;i<A;i++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}else {\n\t\t\tfor(int j=0;j<K;j++) {\n\t\t\t\tans++;\n\t\t\t}\n\t\t}\n\t\tif(B < K-A) {\n\t\t\tfor(int i=0;i<K-A-B;i++) {\n\t\t\t\tans--;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int A = scan.nextInt(); int B = scan.nextInt(); int C = scan.nextInt(); int K = scan.nextInt(); int ans = 0; if(A < K) { for(int i=0;i<A;i++) { ans++; } }else { for(int j=0;j<K;j++) { ans++; } } if(B < K-A) { for(int i=0;i<K-A-B;i++) { ans--; } } System.out.println(ans); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 17, 12, 13, 30, 41, 13, 41, 13, 41, 13, 20, 41, 13, 4, 13, 4, 18, 13, 41, 13, 4, 13, 4, 18, 13, 41, 13, 4, 13, 4, 18, 13, 41, 13, 4, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 4, 18, 13, 2, 2, 13, 13, 13, 17, 14, 2, 13, 17, 30, 0, 13, 4, 18, 13, 13, 13, 4, 18, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 105, 20 ], [ 105, 21 ], [ 21, 22 ], [ 21, 23 ], [ 105, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 26, 29 ], [ 29, 30 ], [ 26, 31 ], [ 31, 32 ], [ 31, 33 ], [ 26, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 26, 41 ], [ 41, 42 ], [ 41, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 46, 47 ], [ 26, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 50, 52 ], [ 52, 53 ], [ 53, 54 ], [ 26, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 26, 62 ], [ 62, 63 ], [ 63, 64 ], [ 26, 65 ], [ 65, 66 ], [ 65, 67 ], [ 26, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 71, 72 ], [ 70, 73 ], [ 70, 74 ], [ 26, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 78, 79 ], [ 77, 80 ], [ 81, 81 ], [ 81, 82 ], [ 81, 83 ], [ 81, 84 ], [ 77, 85 ], [ 26, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 93, 94 ], [ 94, 95 ], [ 93, 96 ], [ 93, 97 ], [ 26, 98 ], [ 98, 99 ], [ 99, 100 ], [ 98, 101 ], [ 24, 102 ], [ 102, 103 ], [ 0, 104 ], [ 104, 105 ], [ 104, 106 ] ]
[ "import java.util.*;\nimport java.io.PrintWriter;\nimport static java.lang.Integer.*;\nimport static java.lang.Long.*;\nimport static java.lang.Math.*;\nimport static java.lang.System.*;\n\npublic class Main {\n\tpublic static final int MOD = 1000000007;\n\tpublic static void main(String[] args) {\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}\n}", "import java.util.*;", "util.*", "java", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import static java.lang.Integer.*;", "import static java.lang.Integer.*;", "import static java.lang.Integer.*;", "import static java.lang.Long.*;", "import static java.lang.Long.*;", "import static java.lang.Long.*;", "import static java.lang.Math.*;", "import static java.lang.Math.*;", "import static java.lang.Math.*;", "import static java.lang.System.*;", "import static java.lang.System.*;", "import static java.lang.System.*;", "public class Main {\n\tpublic static final int MOD = 1000000007;\n\tpublic static void main(String[] args) {\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}\n}", "Main", "public static final int MOD = 1000000007;", "MOD", "1000000007", "public static void main(String[] args) {\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}", "main", "{\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}", "int i", "i", "j;", "j", "Scanner sc = new Scanner(in);", "sc", "new Scanner(in)", "long a = parseLong(sc.next());", "a", "parseLong(sc.next())", "parseLong", "sc.next()", "sc.next", "sc", "long b = parseLong(sc.next());", "b", "parseLong(sc.next())", "parseLong", "sc.next()", "sc.next", "sc", "long c = parseLong(sc.next());", "c", "parseLong(sc.next())", "parseLong", "sc.next()", "sc.next", "sc", "long k = parseLong(sc.next());", "k", "parseLong(sc.next())", "parseLong", "sc.next()", "sc.next", "sc", "sc.close()", "sc.close", "sc", "long ans=0;", "ans", "0", "ans=Math.min(a, k)", "ans", "Math.min(a, k)", "Math.min", "Math", "a", "k", "k=Math.max(k-a-b, 0)", "k", "Math.max(k-a-b, 0)", "Math.max", "Math", "k-a-b", "k-a-b", "k", "a", "b", "0", "if(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}", "k>0", "k", "0", "{\n\t\t\tans-=Math.min(c, k);\n\t\t}", "ans-=Math.min(c, k)", "ans", "Math.min(c, k)", "Math.min", "Math", "c", "k", "out.println(ans)", "out.println", "out", "ans", "String[] args", "args", "public class Main {\n\tpublic static final int MOD = 1000000007;\n\tpublic static void main(String[] args) {\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}\n}", "public class Main {\n\tpublic static final int MOD = 1000000007;\n\tpublic static void main(String[] args) {\n\t\tint i,j;\n\t\tScanner sc = new Scanner(in);\n\t\tlong a = parseLong(sc.next());\n\t\tlong b = parseLong(sc.next());\n\t\tlong c = parseLong(sc.next());\n\t\tlong k = parseLong(sc.next());\n\t\tsc.close();\n\t\tlong ans=0;\n\t\tans=Math.min(a, k);\n\t\tk=Math.max(k-a-b, 0);\n\t\tif(k>0) {\n\t\t\tans-=Math.min(c, k);\n\t\t}\n\t\tout.println(ans);\n\t}\n}", "Main" ]
import java.util.*; import java.io.PrintWriter; import static java.lang.Integer.*; import static java.lang.Long.*; import static java.lang.Math.*; import static java.lang.System.*; public class Main { public static final int MOD = 1000000007; public static void main(String[] args) { int i,j; Scanner sc = new Scanner(in); long a = parseLong(sc.next()); long b = parseLong(sc.next()); long c = parseLong(sc.next()); long k = parseLong(sc.next()); sc.close(); long ans=0; ans=Math.min(a, k); k=Math.max(k-a-b, 0); if(k>0) { ans-=Math.min(c, k); } out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 17, 41, 13, 4, 18, 13, 13, 13, 0, 13, 13, 41, 13, 4, 18, 13, 13, 13, 0, 13, 13, 41, 13, 13, 41, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 40, 41 ], [ 41, 42 ], [ 40, 43 ], [ 40, 44 ], [ 8, 45 ], [ 45, 46 ], [ 45, 47 ], [ 8, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 51, 52 ], [ 50, 53 ], [ 50, 54 ], [ 8, 55 ], [ 55, 56 ], [ 55, 57 ], [ 8, 58 ], [ 58, 59 ], [ 58, 60 ], [ 8, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 63, 65 ], [ 8, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 66, 71 ], [ 6, 72 ], [ 72, 73 ] ]
[ "import java.util.*;\n\nclass Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int sumb = 0;\n int sumc = 0;\n\n /*\n if(K >= A) {\n sumb = K - A;\n if(sumb > 0) {\n sumc = K - A - B;\n }\n System.out.println(A - sumc);\n } else System.out.println(K);\n */\n\n //別解\n int xa = Math.min(A,K);\n K -= xa;\n int xb = Math.min(B,K);\n K -= xb;\n int xc = K;\n int ans = xa -xc;\n System.out.println(ans);\n\n }\n}", "import java.util.*;", "util.*", "java", "class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int sumb = 0;\n int sumc = 0;\n\n /*\n if(K >= A) {\n sumb = K - A;\n if(sumb > 0) {\n sumc = K - A - B;\n }\n System.out.println(A - sumc);\n } else System.out.println(K);\n */\n\n //別解\n int xa = Math.min(A,K);\n K -= xa;\n int xb = Math.min(B,K);\n K -= xb;\n int xc = K;\n int ans = xa -xc;\n System.out.println(ans);\n\n }\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int sumb = 0;\n int sumc = 0;\n\n /*\n if(K >= A) {\n sumb = K - A;\n if(sumb > 0) {\n sumc = K - A - B;\n }\n System.out.println(A - sumc);\n } else System.out.println(K);\n */\n\n //別解\n int xa = Math.min(A,K);\n K -= xa;\n int xb = Math.min(B,K);\n K -= xb;\n int xc = K;\n int ans = xa -xc;\n System.out.println(ans);\n\n }", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int sumb = 0;\n int sumc = 0;\n\n /*\n if(K >= A) {\n sumb = K - A;\n if(sumb > 0) {\n sumc = K - A - B;\n }\n System.out.println(A - sumc);\n } else System.out.println(K);\n */\n\n //別解\n int xa = Math.min(A,K);\n K -= xa;\n int xb = Math.min(B,K);\n K -= xb;\n int xc = K;\n int ans = xa -xc;\n System.out.println(ans);\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int sumb = 0;", "sumb", "0", "int sumc = 0;", "sumc", "0", "int xa = Math.min(A,K);", "xa", "Math.min(A,K)", "Math.min", "Math", "A", "K", "K -= xa", "K", "xa", "int xb = Math.min(B,K);", "xb", "Math.min(B,K)", "Math.min", "Math", "B", "K", "K -= xb", "K", "xb", "int xc = K;", "xc", "K", "int ans = xa -xc;", "ans", "xa -xc", "xa", "xc", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args" ]
import java.util.*; class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int sumb = 0; int sumc = 0; /* if(K >= A) { sumb = K - A; if(sumb > 0) { sumc = K - A - B; } System.out.println(A - sumc); } else System.out.println(K); */ //別解 int xa = Math.min(A,K); K -= xa; int xb = Math.min(B,K); K -= xb; int xc = K; int ans = xa -xc; System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 72, 5 ], [ 72, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 43, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 8, 63 ], [ 63, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 63, 68 ], [ 6, 69 ], [ 69, 70 ], [ 0, 71 ], [ 71, 72 ], [ 71, 73 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "Integer a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "Integer b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "Integer c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "Integer k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "Integer result = 0;", "result", "0", "if(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}", "k <= a", "k", "a", "{\n\t\t\tresult = k;\n\t\t}", "result = k", "result", "k", "if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}", "k <= a+b", "k", "a+b", "a", "b", "{\n\t\t\tresult = a;\n\t\t}", "result = a", "result", "a", "{\n\t\t\tresult = a - (k - a - b);\n\t\t}", "result = a - (k - a - b)", "result", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tInteger a = sc.nextInt();\n\t\tInteger b = sc.nextInt();\n\t\tInteger c = sc.nextInt();\n\t\tInteger k = sc.nextInt();\n\t\t\n\t\tInteger result = 0;\n\t\tif(k <= a) {\n\t\t\tresult = k;\n\t\t} \n\t\telse if(k <= a+b) {\n\t\t\tresult = a;\n\t\t}\n\t\telse{\n\t\t\tresult = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(result);\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); Integer a = sc.nextInt(); Integer b = sc.nextInt(); Integer c = sc.nextInt(); Integer k = sc.nextInt(); Integer result = 0; if(k <= a) { result = k; } else if(k <= a+b) { result = a; } else{ result = a - (k - a - b); } System.out.println(result); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 2, 13, 13, 4, 18, 18, 13, 13, 4, 18, 13, 13, 13, 14, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 17, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 4, 18, 13, 29, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 162, 8 ], [ 162, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 11, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 11, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 11, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 38, 40 ], [ 35, 41 ], [ 41, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 41, 46 ], [ 46, 47 ], [ 47, 48 ], [ 46, 49 ], [ 46, 50 ], [ 35, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 55, 55 ], [ 55, 56 ], [ 55, 57 ], [ 55, 58 ], [ 51, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 59, 64 ], [ 64, 65 ], [ 64, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 9, 71 ], [ 71, 72 ], [ 162, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 73, 77 ], [ 77, 78 ], [ 73, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 82, 83 ], [ 82, 84 ], [ 73, 85 ], [ 85, 86 ], [ 85, 87 ], [ 87, 88 ], [ 88, 89 ], [ 89, 90 ], [ 90, 91 ], [ 90, 92 ], [ 89, 93 ], [ 93, 94 ], [ 94, 95 ], [ 95, 96 ], [ 88, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 101, 102 ], [ 102, 103 ], [ 103, 104 ], [ 98, 105 ], [ 105, 106 ], [ 106, 107 ], [ 106, 108 ], [ 87, 109 ], [ 109, 110 ], [ 110, 111 ], [ 111, 112 ], [ 73, 113 ], [ 113, 114 ], [ 113, 115 ], [ 115, 116 ], [ 116, 117 ], [ 117, 118 ], [ 118, 119 ], [ 117, 120 ], [ 120, 121 ], [ 73, 122 ], [ 122, 123 ], [ 122, 124 ], [ 124, 125 ], [ 125, 126 ], [ 126, 127 ], [ 127, 128 ], [ 126, 129 ], [ 129, 130 ], [ 73, 131 ], [ 131, 132 ], [ 131, 133 ], [ 133, 134 ], [ 134, 135 ], [ 135, 136 ], [ 136, 137 ], [ 135, 138 ], [ 138, 139 ], [ 73, 140 ], [ 140, 141 ], [ 140, 142 ], [ 142, 143 ], [ 143, 144 ], [ 143, 145 ], [ 142, 146 ], [ 146, 147 ], [ 147, 148 ], [ 147, 149 ], [ 149, 150 ], [ 150, 151 ], [ 151, 152 ], [ 146, 153 ], [ 153, 154 ], [ 154, 155 ], [ 154, 156 ], [ 156, 157 ], [ 157, 158 ], [ 142, 159 ], [ 159, 160 ], [ 0, 161 ], [ 161, 162 ], [ 161, 163 ] ]
[ "/*\n *created by Kraken on 12-05-2020 at 15:31\n */\nimport java.util.*;\nimport java.io.*;\n\npublic class Main {\n\n public static void main(String[] args) {\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }\n\n static class FastReader {\n\n BufferedReader br;\n\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n}", "import java.util.*;", "util.*", "java", "import java.io.*;", "io.*", "java", "public class Main {\n\n public static void main(String[] args) {\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }\n\n static class FastReader {\n\n BufferedReader br;\n\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n}", "Main", "public static void main(String[] args) {\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }", "main", "{\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }", "FastReader sc = new FastReader();", "sc", "new FastReader()", "long a = sc.nextLong()", "a", "sc.nextLong()", "sc.nextLong", "sc", "b = sc.nextLong()", "b", "sc.nextLong()", "sc.nextLong", "sc", "c = sc.nextLong()", "c", "sc.nextLong()", "sc.nextLong", "sc", "k = sc.nextLong();", "k", "sc.nextLong()", "sc.nextLong", "sc", "if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));", "k <= a + b", "k", "a + b", "a", "b", "System.out.println(Math.min(k, a))", "System.out.println", "System.out", "System", "System.out", "Math.min(k, a)", "Math.min", "Math", "k", "a", "if (k <= a + b + c)\n System.out.println(a - (k - a - b));", "k <= a + b + c", "k", "a + b + c", "a + b + c", "a", "b", "c", "System.out.println(a - (k - a - b))", "System.out.println", "System.out", "System", "System.out", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "String[] args", "args", "static class FastReader {\n\n BufferedReader br;\n\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }", "FastReader", "BufferedReader br;", "br", "StringTokenizer st;", "st", "public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "FastReader", "{\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "br = new BufferedReader(new InputStreamReader(System.in))", "br", "new BufferedReader(new InputStreamReader(System.in))", "String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }", "st == null || !st.hasMoreElements()", "st == null", "st", "null", "!st.hasMoreElements()", "st.hasMoreElements()", "st.hasMoreElements", "st", "{\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }", "try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n st = new StringTokenizer(br.readLine());\n }", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "int nextInt() {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "long nextLong() {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "double nextDouble() {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "nextLine", "{\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "String str = \"\";", "str", "\"\"", "try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n str = br.readLine();\n }", "str = br.readLine()", "str", "br.readLine()", "br.readLine", "br", "return str;", "str", "public class Main {\n\n public static void main(String[] args) {\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }\n\n static class FastReader {\n\n BufferedReader br;\n\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n FastReader sc = new FastReader();\n long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong();\n if (k <= a + b)\n System.out.println(Math.min(k, a));\n else if (k <= a + b + c)\n System.out.println(a - (k - a - b));\n }\n\n static class FastReader {\n\n BufferedReader br;\n\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n }\n catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n}", "Main" ]
/* *created by Kraken on 12-05-2020 at 15:31 */ import java.util.*; import java.io.*; public class Main { public static void main(String[] args) { FastReader sc = new FastReader(); long a = sc.nextLong(), b = sc.nextLong(), c = sc.nextLong(), k = sc.nextLong(); if (k <= a + b) System.out.println(Math.min(k, a)); else if (k <= a + b + c) System.out.println(a - (k - a - b)); } static class FastReader { BufferedReader br; StringTokenizer st; public FastReader() { br = new BufferedReader(new InputStreamReader(System.in)); } String next() { while (st == null || !st.hasMoreElements()) { try { st = new StringTokenizer(br.readLine()); } catch (IOException e) { e.printStackTrace(); } } return st.nextToken(); } int nextInt() { return Integer.parseInt(next()); } long nextLong() { return Long.parseLong(next()); } double nextDouble() { return Double.parseDouble(next()); } String nextLine() { String str = ""; try { str = br.readLine(); } catch (IOException e) { e.printStackTrace(); } return str; } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 17, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 13, 13, 13, 30, 0, 13, 13, 0, 13, 2, 2, 13, 13, 13, 30, 0, 13, 2, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 87, 5 ], [ 87, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 8, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 41, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 45, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 50, 54 ], [ 49, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 55, 59 ], [ 59, 60 ], [ 59, 61 ], [ 62, 62 ], [ 62, 63 ], [ 62, 64 ], [ 62, 65 ], [ 49, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 69, 70 ], [ 69, 71 ], [ 41, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 8, 76 ], [ 76, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 76, 81 ], [ 81, 82 ], [ 81, 83 ], [ 6, 84 ], [ 84, 85 ], [ 0, 86 ], [ 86, 87 ], [ 86, 88 ] ]
[ "import java.util.Scanner;\n \npublic class Main {\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }", "main", "{\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int Amax = scan.nextInt();", "Amax", "scan.nextInt()", "scan.nextInt", "scan", "int Bmax = scan.nextInt();", "Bmax", "scan.nextInt()", "scan.nextInt", "scan", "int Cmax = scan.nextInt();", "Cmax", "scan.nextInt()", "scan.nextInt", "scan", "int kosu = scan.nextInt();", "kosu", "scan.nextInt()", "scan.nextInt", "scan", "int Akosu = 0;", "Akosu", "0", "int Bkosu = 0;", "Bkosu", "0", "int Ckosu = 0;", "Ckosu", "0", "if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }", "Amax < kosu", "Amax", "kosu", "{\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n }", "Akosu = Amax", "Akosu", "Amax", "if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }", "(Amax + Bmax) < kosu", "(Amax + Bmax)", "Amax", "Bmax", "kosu", "{\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n }", "Bkosu = Bmax", "Bkosu", "Bmax", "Ckosu = kosu - Bmax - Amax", "Ckosu", "kosu - Bmax - Amax", "kosu - Bmax - Amax", "kosu", "Bmax", "Amax", "{\n Bkosu = kosu - Amax;\n }", "Bkosu = kosu - Amax", "Bkosu", "kosu - Amax", "kosu", "Amax", "{\n Akosu = kosu;\n }", "Akosu = kosu", "Akosu", "kosu", "System.out.println(Akosu - Ckosu)", "System.out.println", "System.out", "System", "System.out", "Akosu - Ckosu", "Akosu", "Ckosu", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int Amax = scan.nextInt();\n int Bmax = scan.nextInt();\n int Cmax = scan.nextInt();\n int kosu = scan.nextInt();\n\t\tint Akosu = 0;\n int Bkosu = 0;\n int Ckosu = 0;\n if (Amax < kosu) {\n Akosu = Amax;\n if ((Amax + Bmax) < kosu) {\n Bkosu = Bmax;\n Ckosu = kosu - Bmax - Amax;\n } else {\n Bkosu = kosu - Amax;\n }\n } else {\n Akosu = kosu;\n }\n System.out.println(Akosu - Ckosu);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int Amax = scan.nextInt(); int Bmax = scan.nextInt(); int Cmax = scan.nextInt(); int kosu = scan.nextInt(); int Akosu = 0; int Bkosu = 0; int Ckosu = 0; if (Amax < kosu) { Akosu = Amax; if ((Amax + Bmax) < kosu) { Bkosu = Bmax; Ckosu = kosu - Bmax - Amax; } else { Bkosu = kosu - Amax; } } else { Akosu = kosu; } System.out.println(Akosu - Ckosu); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 41, 13, 41, 13, 2, 17, 17, 41, 13, 2, 18, 13, 13, 17, 12, 13, 30, 41, 13, 4, 18, 13, 17, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 18, 13, 13, 13, 0, 13, 13, 0, 13, 2, 18, 13, 13, 13, 4, 18, 13, 13, 12, 13, 30, 4, 18, 20, 23, 13, 12, 13, 30, 0, 13, 20, 0, 13, 20, 4, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 6, 13, 41, 13, 12, 13, 30, 4, 13, 18, 13, 13, 12, 13, 30, 0, 18, 36, 13, 20, 23, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 4, 18, 18, 36, 13, 12, 13, 30, 29, 4, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 29, 40, 17, 30, 41, 13, 17, 41, 13, 4, 18, 13, 42, 2, 2, 2, 2, 13, 17, 2, 17, 13, 2, 13, 17, 2, 13, 17, 30, 0, 13, 4, 18, 13, 14, 2, 13, 17, 30, 0, 13, 40, 17, 0, 13, 4, 18, 13, 14, 2, 13, 17, 30, 0, 13, 4, 18, 13, 41, 13, 2, 13, 17, 42, 17, 30, 0, 13, 4, 18, 13, 14, 2, 2, 13, 17, 2, 17, 13, 29, 2, 13, 13, 0, 13, 17, 0, 13, 2, 13, 17, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 29, 18, 13, 13, 30, 41, 13, 17, 41, 13, 4, 18, 13, 42, 2, 2, 2, 2, 13, 17, 2, 17, 13, 2, 13, 17, 2, 13, 17, 30, 0, 13, 4, 18, 13, 14, 2, 13, 17, 30, 0, 13, 40, 17, 0, 13, 4, 18, 13, 14, 2, 13, 17, 30, 0, 13, 4, 18, 13, 41, 13, 2, 13, 17, 42, 17, 30, 0, 13, 4, 18, 13, 14, 2, 2, 13, 17, 2, 17, 13, 3, 0, 13, 17, 0, 13, 2, 13, 17, 14, 2, 13, 17, 29, 2, 13, 13, 41, 13, 17, 0, 13, 4, 18, 13, 42, 2, 2, 17, 13, 2, 13, 17, 30, 0, 13, 17, 0, 13, 2, 13, 17, 0, 13, 17, 0, 13, 4, 18, 13, 29, 2, 2, 13, 13, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 29, 17, 30, 41, 13, 4, 18, 13, 42, 4, 18, 13, 13, 30, 0, 13, 4, 18, 13, 29, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 29, 17, 30, 41, 13, 20, 41, 13, 4, 18, 13, 42, 4, 18, 13, 13, 30, 0, 13, 4, 18, 13, 42, 2, 2, 13, 40, 17, 40, 4, 18, 13, 13, 30, 4, 18, 13, 13, 0, 13, 4, 18, 13, 29, 4, 18, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 29, 17, 30, 41, 13, 20, 41, 13, 4, 18, 13, 42, 2, 2, 13, 40, 17, 2, 13, 17, 30, 4, 18, 13, 13, 0, 13, 4, 18, 13, 29, 4, 18, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 2, 4, 13, 17, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 2, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 2, 13, 17, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 2, 4, 13, 17, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 2, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 2, 13, 17, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 758, 11 ], [ 758, 12 ], [ 12, 13 ], [ 758, 14 ], [ 14, 15 ], [ 758, 16 ], [ 16, 17 ], [ 16, 18 ], [ 18, 19 ], [ 18, 20 ], [ 758, 21 ], [ 21, 22 ], [ 21, 23 ], [ 23, 24 ], [ 24, 25 ], [ 24, 26 ], [ 23, 27 ], [ 758, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 31, 33 ], [ 33, 34 ], [ 34, 35 ], [ 33, 36 ], [ 30, 37 ], [ 37, 38 ], [ 37, 39 ], [ 30, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 43, 44 ], [ 30, 45 ], [ 45, 46 ], [ 45, 47 ], [ 30, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 48, 53 ], [ 53, 54 ], [ 53, 55 ], [ 48, 56 ], [ 56, 57 ], [ 57, 58 ], [ 48, 59 ], [ 60, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 64, 65 ], [ 63, 66 ], [ 66, 67 ], [ 66, 68 ], [ 63, 69 ], [ 60, 70 ], [ 70, 71 ], [ 70, 72 ], [ 60, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 75, 79 ], [ 30, 80 ], [ 80, 81 ], [ 81, 82 ], [ 80, 83 ], [ 758, 84 ], [ 84, 85 ], [ 84, 86 ], [ 86, 87 ], [ 87, 88 ], [ 88, 89 ], [ 84, 90 ], [ 90, 91 ], [ 758, 92 ], [ 92, 93 ], [ 92, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 98, 100 ], [ 94, 101 ], [ 101, 102 ], [ 94, 103 ], [ 103, 104 ], [ 104, 105 ], [ 94, 106 ], [ 106, 107 ], [ 107, 108 ], [ 94, 109 ], [ 109, 110 ], [ 110, 111 ], [ 758, 112 ], [ 112, 113 ], [ 112, 114 ], [ 114, 115 ], [ 112, 116 ], [ 116, 117 ], [ 116, 118 ], [ 118, 119 ], [ 119, 120 ], [ 119, 121 ], [ 121, 122 ], [ 121, 123 ], [ 112, 124 ], [ 124, 125 ], [ 124, 126 ], [ 126, 127 ], [ 127, 128 ], [ 128, 129 ], [ 128, 130 ], [ 127, 131 ], [ 124, 132 ], [ 132, 133 ], [ 112, 134 ], [ 134, 135 ], [ 134, 136 ], [ 136, 137 ], [ 137, 138 ], [ 138, 139 ], [ 138, 140 ], [ 140, 141 ], [ 141, 142 ], [ 142, 143 ], [ 137, 144 ], [ 144, 145 ], [ 145, 146 ], [ 146, 147 ], [ 147, 148 ], [ 147, 149 ], [ 112, 150 ], [ 150, 151 ], [ 150, 152 ], [ 152, 153 ], [ 153, 154 ], [ 154, 155 ], [ 112, 156 ], [ 156, 157 ], [ 156, 158 ], [ 158, 159 ], [ 159, 160 ], [ 160, 161 ], [ 160, 162 ], [ 162, 163 ], [ 163, 164 ], [ 164, 165 ], [ 162, 166 ], [ 166, 167 ], [ 167, 168 ], [ 159, 169 ], [ 169, 170 ], [ 170, 171 ], [ 170, 172 ], [ 169, 173 ], [ 173, 174 ], [ 173, 175 ], [ 175, 176 ], [ 176, 177 ], [ 169, 178 ], [ 178, 179 ], [ 180, 180 ], [ 180, 181 ], [ 181, 182 ], [ 182, 183 ], [ 182, 184 ], [ 181, 185 ], [ 185, 186 ], [ 185, 187 ], [ 180, 188 ], [ 188, 189 ], [ 188, 190 ], [ 180, 191 ], [ 191, 192 ], [ 191, 193 ], [ 178, 194 ], [ 194, 195 ], [ 195, 196 ], [ 195, 197 ], [ 197, 198 ], [ 198, 199 ], [ 169, 200 ], [ 200, 201 ], [ 201, 202 ], [ 201, 203 ], [ 200, 204 ], [ 204, 205 ], [ 205, 206 ], [ 205, 207 ], [ 207, 208 ], [ 204, 209 ], [ 209, 210 ], [ 209, 211 ], [ 211, 212 ], [ 212, 213 ], [ 200, 214 ], [ 214, 215 ], [ 215, 216 ], [ 215, 217 ], [ 214, 218 ], [ 218, 219 ], [ 219, 220 ], [ 219, 221 ], [ 221, 222 ], [ 222, 223 ], [ 169, 224 ], [ 224, 225 ], [ 224, 226 ], [ 226, 227 ], [ 226, 228 ], [ 169, 229 ], [ 229, 230 ], [ 229, 231 ], [ 231, 232 ], [ 232, 233 ], [ 232, 234 ], [ 234, 235 ], [ 235, 236 ], [ 231, 237 ], [ 237, 238 ], [ 238, 239 ], [ 239, 240 ], [ 239, 241 ], [ 238, 242 ], [ 242, 243 ], [ 242, 244 ], [ 237, 245 ], [ 245, 246 ], [ 246, 247 ], [ 246, 248 ], [ 231, 249 ], [ 249, 250 ], [ 249, 251 ], [ 231, 252 ], [ 252, 253 ], [ 252, 254 ], [ 254, 255 ], [ 254, 256 ], [ 112, 257 ], [ 257, 258 ], [ 257, 259 ], [ 259, 260 ], [ 260, 261 ], [ 261, 262 ], [ 261, 263 ], [ 263, 264 ], [ 264, 265 ], [ 265, 266 ], [ 263, 267 ], [ 267, 268 ], [ 268, 269 ], [ 268, 270 ], [ 260, 271 ], [ 271, 272 ], [ 272, 273 ], [ 272, 274 ], [ 271, 275 ], [ 275, 276 ], [ 275, 277 ], [ 277, 278 ], [ 278, 279 ], [ 271, 280 ], [ 280, 281 ], [ 282, 282 ], [ 282, 283 ], [ 283, 284 ], [ 284, 285 ], [ 284, 286 ], [ 283, 287 ], [ 287, 288 ], [ 287, 289 ], [ 282, 290 ], [ 290, 291 ], [ 290, 292 ], [ 282, 293 ], [ 293, 294 ], [ 293, 295 ], [ 280, 296 ], [ 296, 297 ], [ 297, 298 ], [ 297, 299 ], [ 299, 300 ], [ 300, 301 ], [ 271, 302 ], [ 302, 303 ], [ 303, 304 ], [ 303, 305 ], [ 302, 306 ], [ 306, 307 ], [ 307, 308 ], [ 307, 309 ], [ 309, 310 ], [ 306, 311 ], [ 311, 312 ], [ 311, 313 ], [ 313, 314 ], [ 314, 315 ], [ 302, 316 ], [ 316, 317 ], [ 317, 318 ], [ 317, 319 ], [ 316, 320 ], [ 320, 321 ], [ 321, 322 ], [ 321, 323 ], [ 323, 324 ], [ 324, 325 ], [ 271, 326 ], [ 326, 327 ], [ 326, 328 ], [ 328, 329 ], [ 328, 330 ], [ 271, 331 ], [ 331, 332 ], [ 331, 333 ], [ 333, 334 ], [ 334, 335 ], [ 334, 336 ], [ 336, 337 ], [ 337, 338 ], [ 333, 339 ], [ 339, 340 ], [ 340, 341 ], [ 341, 342 ], [ 341, 343 ], [ 340, 344 ], [ 344, 345 ], [ 344, 346 ], [ 339, 347 ], [ 333, 348 ], [ 348, 349 ], [ 348, 350 ], [ 333, 351 ], [ 351, 352 ], [ 351, 353 ], [ 353, 354 ], [ 353, 355 ], [ 271, 356 ], [ 356, 357 ], [ 357, 358 ], [ 357, 359 ], [ 356, 360 ], [ 360, 361 ], [ 361, 362 ], [ 361, 363 ], [ 271, 364 ], [ 364, 365 ], [ 364, 366 ], [ 271, 367 ], [ 367, 368 ], [ 367, 369 ], [ 369, 370 ], [ 370, 371 ], [ 271, 372 ], [ 372, 373 ], [ 373, 374 ], [ 374, 375 ], [ 374, 376 ], [ 373, 377 ], [ 377, 378 ], [ 377, 379 ], [ 372, 380 ], [ 380, 381 ], [ 381, 382 ], [ 381, 383 ], [ 380, 384 ], [ 384, 385 ], [ 384, 386 ], [ 386, 387 ], [ 386, 388 ], [ 380, 389 ], [ 389, 390 ], [ 389, 391 ], [ 380, 392 ], [ 392, 393 ], [ 392, 394 ], [ 394, 395 ], [ 395, 396 ], [ 271, 397 ], [ 397, 398 ], [ 398, 399 ], [ 399, 400 ], [ 399, 401 ], [ 398, 402 ], [ 112, 403 ], [ 403, 404 ], [ 403, 405 ], [ 405, 406 ], [ 406, 407 ], [ 407, 408 ], [ 407, 409 ], [ 409, 410 ], [ 410, 411 ], [ 411, 412 ], [ 409, 413 ], [ 413, 414 ], [ 406, 415 ], [ 415, 416 ], [ 416, 417 ], [ 416, 418 ], [ 418, 419 ], [ 419, 420 ], [ 415, 421 ], [ 421, 422 ], [ 422, 423 ], [ 423, 424 ], [ 422, 425 ], [ 421, 426 ], [ 426, 427 ], [ 427, 428 ], [ 427, 429 ], [ 429, 430 ], [ 430, 431 ], [ 415, 432 ], [ 432, 433 ], [ 112, 434 ], [ 434, 435 ], [ 434, 436 ], [ 436, 437 ], [ 437, 438 ], [ 438, 439 ], [ 438, 440 ], [ 440, 441 ], [ 441, 442 ], [ 442, 443 ], [ 440, 444 ], [ 444, 445 ], [ 437, 446 ], [ 446, 447 ], [ 447, 448 ], [ 447, 449 ], [ 446, 450 ], [ 450, 451 ], [ 450, 452 ], [ 452, 453 ], [ 453, 454 ], [ 446, 455 ], [ 455, 456 ], [ 456, 457 ], [ 457, 458 ], [ 456, 459 ], [ 455, 460 ], [ 460, 461 ], [ 461, 462 ], [ 461, 463 ], [ 463, 464 ], [ 464, 465 ], [ 446, 466 ], [ 466, 467 ], [ 467, 468 ], [ 468, 469 ], [ 468, 470 ], [ 470, 471 ], [ 467, 472 ], [ 472, 473 ], [ 473, 474 ], [ 474, 475 ], [ 473, 476 ], [ 466, 477 ], [ 477, 478 ], [ 478, 479 ], [ 479, 480 ], [ 478, 481 ], [ 477, 482 ], [ 482, 483 ], [ 482, 484 ], [ 484, 485 ], [ 485, 486 ], [ 446, 487 ], [ 487, 488 ], [ 488, 489 ], [ 489, 490 ], [ 112, 491 ], [ 491, 492 ], [ 491, 493 ], [ 493, 494 ], [ 494, 495 ], [ 495, 496 ], [ 495, 497 ], [ 497, 498 ], [ 498, 499 ], [ 499, 500 ], [ 497, 501 ], [ 501, 502 ], [ 494, 503 ], [ 503, 504 ], [ 504, 505 ], [ 504, 506 ], [ 503, 507 ], [ 507, 508 ], [ 507, 509 ], [ 509, 510 ], [ 510, 511 ], [ 503, 512 ], [ 512, 513 ], [ 513, 514 ], [ 514, 515 ], [ 514, 516 ], [ 516, 517 ], [ 513, 518 ], [ 518, 519 ], [ 518, 520 ], [ 512, 521 ], [ 521, 522 ], [ 522, 523 ], [ 523, 524 ], [ 522, 525 ], [ 521, 526 ], [ 526, 527 ], [ 526, 528 ], [ 528, 529 ], [ 529, 530 ], [ 503, 531 ], [ 531, 532 ], [ 532, 533 ], [ 533, 534 ], [ 112, 535 ], [ 535, 536 ], [ 535, 537 ], [ 537, 538 ], [ 538, 539 ], [ 538, 540 ], [ 537, 542 ], [ 542, 543 ], [ 543, 544 ], [ 544, 545 ], [ 544, 546 ], [ 542, 547 ], [ 547, 548 ], [ 547, 549 ], [ 542, 550 ], [ 550, 551 ], [ 551, 552 ], [ 542, 553 ], [ 554, 554 ], [ 554, 555 ], [ 555, 556 ], [ 556, 557 ], [ 556, 558 ], [ 555, 559 ], [ 559, 560 ], [ 537, 561 ], [ 561, 562 ], [ 535, 563 ], [ 563, 564 ], [ 112, 565 ], [ 565, 566 ], [ 565, 567 ], [ 567, 568 ], [ 568, 569 ], [ 568, 570 ], [ 567, 572 ], [ 572, 573 ], [ 573, 574 ], [ 574, 575 ], [ 574, 576 ], [ 572, 577 ], [ 577, 578 ], [ 577, 579 ], [ 572, 580 ], [ 580, 581 ], [ 581, 582 ], [ 572, 583 ], [ 584, 584 ], [ 584, 585 ], [ 585, 586 ], [ 586, 587 ], [ 586, 588 ], [ 585, 589 ], [ 589, 590 ], [ 590, 591 ], [ 589, 592 ], [ 567, 593 ], [ 593, 594 ], [ 565, 595 ], [ 595, 596 ], [ 112, 597 ], [ 597, 598 ], [ 597, 599 ], [ 599, 600 ], [ 600, 601 ], [ 600, 602 ], [ 603, 604 ], [ 603, 605 ], [ 599, 606 ], [ 606, 607 ], [ 607, 608 ], [ 608, 609 ], [ 608, 610 ], [ 606, 611 ], [ 611, 612 ], [ 611, 613 ], [ 606, 614 ], [ 614, 615 ], [ 615, 616 ], [ 606, 617 ], [ 618, 618 ], [ 618, 619 ], [ 619, 620 ], [ 620, 621 ], [ 620, 622 ], [ 622, 623 ], [ 622, 624 ], [ 619, 625 ], [ 625, 626 ], [ 599, 627 ], [ 627, 628 ], [ 597, 629 ], [ 629, 630 ], [ 112, 631 ], [ 631, 632 ], [ 631, 633 ], [ 633, 634 ], [ 634, 635 ], [ 634, 636 ], [ 633, 638 ], [ 638, 639 ], [ 639, 640 ], [ 640, 641 ], [ 640, 642 ], [ 638, 643 ], [ 643, 644 ], [ 643, 645 ], [ 638, 646 ], [ 646, 647 ], [ 647, 648 ], [ 638, 649 ], [ 650, 650 ], [ 650, 651 ], [ 651, 652 ], [ 652, 653 ], [ 652, 654 ], [ 651, 655 ], [ 655, 656 ], [ 633, 657 ], [ 657, 658 ], [ 631, 659 ], [ 659, 660 ], [ 112, 661 ], [ 661, 662 ], [ 661, 663 ], [ 663, 664 ], [ 664, 665 ], [ 664, 666 ], [ 663, 668 ], [ 668, 669 ], [ 669, 670 ], [ 670, 671 ], [ 670, 672 ], [ 668, 673 ], [ 673, 674 ], [ 673, 675 ], [ 668, 676 ], [ 676, 677 ], [ 677, 678 ], [ 668, 679 ], [ 680, 680 ], [ 680, 681 ], [ 681, 682 ], [ 682, 683 ], [ 682, 684 ], [ 681, 685 ], [ 685, 686 ], [ 686, 687 ], [ 685, 688 ], [ 663, 689 ], [ 689, 690 ], [ 661, 691 ], [ 691, 692 ], [ 112, 693 ], [ 693, 694 ], [ 693, 695 ], [ 695, 696 ], [ 696, 697 ], [ 696, 698 ], [ 699, 700 ], [ 699, 701 ], [ 695, 702 ], [ 702, 703 ], [ 703, 704 ], [ 704, 705 ], [ 704, 706 ], [ 702, 707 ], [ 707, 708 ], [ 707, 709 ], [ 702, 710 ], [ 710, 711 ], [ 711, 712 ], [ 702, 713 ], [ 714, 714 ], [ 714, 715 ], [ 715, 716 ], [ 716, 717 ], [ 716, 718 ], [ 718, 719 ], [ 718, 720 ], [ 715, 721 ], [ 721, 722 ], [ 695, 723 ], [ 723, 724 ], [ 693, 725 ], [ 725, 726 ], [ 112, 727 ], [ 727, 728 ], [ 727, 729 ], [ 729, 730 ], [ 730, 731 ], [ 730, 732 ], [ 729, 734 ], [ 734, 735 ], [ 735, 736 ], [ 736, 737 ], [ 736, 738 ], [ 734, 739 ], [ 739, 740 ], [ 739, 741 ], [ 734, 742 ], [ 742, 743 ], [ 743, 744 ], [ 734, 745 ], [ 746, 746 ], [ 746, 747 ], [ 747, 748 ], [ 748, 749 ], [ 748, 750 ], [ 747, 751 ], [ 751, 752 ], [ 729, 753 ], [ 753, 754 ], [ 727, 755 ], [ 755, 756 ], [ 0, 757 ], [ 757, 758 ], [ 757, 759 ] ]
[ "import jdk.nashorn.api.scripting.ScriptObjectMirror;\n\nimport java.io.*;\nimport java.util.*;\n\n@SuppressWarnings(\"unused\")\npublic class Main {\n FastScanner in;\n PrintWriter out;\n final static int MOD = (int)1e9+7;\n final static long INF = Long.MAX_VALUE / 2;\n \n void solve(){\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }\n \n public static void main(String[] args) {\n new Main().m();\n }\n \n private void m() {\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }\n \n static class FastScanner {\n private Reader input;\n \n public FastScanner() {this(System.in);}\n public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}\n public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n \n public int nextInt() {return (int) nextLong();}\n \n public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }\n \n public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }\n \n public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }\n \n public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }\n \n public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }\n \n public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }\n \n public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }\n \n public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }\n \n public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }\n \n public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }\n }\n}", "import jdk.nashorn.api.scripting.ScriptObjectMirror;", "ScriptObjectMirror", "jdk.nashorn.api.scripting", "import java.io.*;", "io.*", "java", "import java.util.*;", "util.*", "java", "public class Main {\n FastScanner in;\n PrintWriter out;\n final static int MOD = (int)1e9+7;\n final static long INF = Long.MAX_VALUE / 2;\n \n void solve(){\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }\n \n public static void main(String[] args) {\n new Main().m();\n }\n \n private void m() {\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }\n \n static class FastScanner {\n private Reader input;\n \n public FastScanner() {this(System.in);}\n public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}\n public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n \n public int nextInt() {return (int) nextLong();}\n \n public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }\n \n public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }\n \n public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }\n \n public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }\n \n public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }\n \n public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }\n \n public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }\n \n public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }\n \n public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }\n \n public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }\n }\n}", "Main", "FastScanner in;", "in", "PrintWriter out;", "out", "final static int MOD = (int)1e9+7;", "MOD", "(int)1e9+7", "(int)1e9", "7", "final static long INF = Long.MAX_VALUE / 2;", "INF", "Long.MAX_VALUE / 2", "Long.MAX_VALUE", "Long", "Long.MAX_VALUE", "2", "void solve(){\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }", "solve", "{\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }", "int[] a = in.nextIntArray(3);", "a", "in.nextIntArray(3)", "in.nextIntArray", "in", "3", "int[] b = new int[]{1, 0, -1};", "b", "new int[]{1, 0, -1}", "int K = in.nextInt();", "K", "in.nextInt()", "in.nextInt", "in", "long sum = 0;", "sum", "0", "for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }", "int i = 0;", "int i = 0;", "i", "0", "i < 3", "i", "3", "i++", "i++", "i", "{\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }", "{\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }", "long k = Math.min(a[i], K);", "k", "Math.min(a[i], K)", "Math.min", "Math", "a[i]", "a", "i", "K", "K -= k", "K", "k", "sum += b[i] * k", "sum", "b[i] * k", "b[i]", "b", "i", "k", "out.println(sum)", "out.println", "out", "sum", "public static void main(String[] args) {\n new Main().m();\n }", "main", "{\n new Main().m();\n }", "new Main().m()", "new Main().m", "new Main()", "String[] args", "args", "private void m() {\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }", "m", "{\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }", "in = new FastScanner(System.in)", "in", "new FastScanner(System.in)", "out = new PrintWriter(System.out)", "out", "new PrintWriter(System.out)", "solve()", "solve", "out.flush()", "out.flush", "out", "in.close()", "in.close", "in", "out.close()", "out.close", "out", "static class FastScanner {\n private Reader input;\n \n public FastScanner() {this(System.in);}\n public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}\n public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n \n public int nextInt() {return (int) nextLong();}\n \n public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }\n \n public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }\n \n public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }\n \n public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }\n \n public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }\n \n public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }\n \n public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }\n \n public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }\n \n public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }\n \n public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }\n }", "FastScanner", "private Reader input;", "input", "public FastScanner() {this(System.in);}", "FastScanner", "{this(System.in);}", "this(System.in)", "this", "System.in", "System", "System.in", "public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}", "FastScanner", "{this.input = new BufferedReader(new InputStreamReader(stream));}", "this.input = new BufferedReader(new InputStreamReader(stream))", "this.input", "this", "this.input", "new BufferedReader(new InputStreamReader(stream))", "InputStream stream", "stream", "public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "close", "{\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n this.input.close();\n }", "this.input.close()", "this.input.close", "this.input", "this", "this.input", "public int nextInt() {return (int) nextLong();}", "nextInt", "{return (int) nextLong();}", "return (int) nextLong();", "(int) nextLong()", "nextLong", "public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }", "nextLong", "{\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }", "try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }", "catch (IOException e) {\n e.printStackTrace();\n return -1;\n }", "IOException e", "{\n e.printStackTrace();\n return -1;\n }", "e.printStackTrace()", "e.printStackTrace", "e", "return -1;", "-1", "1", "{\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n }", "int sign = 1;", "sign", "1", "int b = input.read();", "b", "input.read()", "input.read", "input", "while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }", "(b < '0' || '9' < b) && b != '-' && b != '+'", "(b < '0' || '9' < b) && b != '-' && b != '+'", "(b < '0' || '9' < b)", "b < '0'", "b", "'0'", "'9' < b", "'9'", "b", "b != '-'", "b", "'-'", "b != '+'", "b", "'+'", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }", "b == '-'", "b", "'-'", "{\n sign = -1;\n b = input.read();\n }", "sign = -1", "sign", "-1", "1", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b == '+') {\n b = input.read();\n }", "b == '+'", "b", "'+'", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "long ret = b - '0';", "ret", "b - '0'", "b", "'0'", "while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }", "true", "{\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b < '0' || '9' < b) return ret * sign;", "b < '0' || '9' < b", "b < '0'", "b", "'0'", "'9' < b", "'9'", "b", "return ret * sign;", "ret * sign", "ret", "sign", "ret *= 10", "ret", "10", "ret += b - '0'", "ret", "b - '0'", "b", "'0'", "public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }", "nextDouble", "{\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }", "try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }", "catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }", "IOException e", "{\n e.printStackTrace();\n return Double.NaN;\n }", "e.printStackTrace()", "e.printStackTrace", "e", "return Double.NaN;", "Double.NaN", "Double", "Double.NaN", "{\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n }", "double sign = 1;", "sign", "1", "int b = input.read();", "b", "input.read()", "input.read", "input", "while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }", "(b < '0' || '9' < b) && b != '-' && b != '+'", "(b < '0' || '9' < b) && b != '-' && b != '+'", "(b < '0' || '9' < b)", "b < '0'", "b", "'0'", "'9' < b", "'9'", "b", "b != '-'", "b", "'-'", "b != '+'", "b", "'+'", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }", "b == '-'", "b", "'-'", "{\n sign = -1;\n b = input.read();\n }", "sign = -1", "sign", "-1", "1", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b == '+') {\n b = input.read();\n }", "b == '+'", "b", "'+'", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "double ret = b - '0';", "ret", "b - '0'", "b", "'0'", "while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }", "true", "{\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "if (b < '0' || '9' < b) break;", "b < '0' || '9' < b", "b < '0'", "b", "'0'", "'9' < b", "'9'", "b", "break;", "ret *= 10", "ret", "10", "ret += b - '0'", "ret", "b - '0'", "b", "'0'", "if (b != '.') return sign * ret;", "b != '.'", "b", "'.'", "return sign * ret;", "sign * ret", "sign", "ret", "double div = 1;", "div", "1", "b = input.read()", "b", "input.read()", "input.read", "input", "while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }", "'0' <= b && b <= '9'", "'0' <= b", "'0'", "b", "b <= '9'", "b", "'9'", "{\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }", "ret *= 10", "ret", "10", "ret += b - '0'", "ret", "b - '0'", "b", "'0'", "div *= 10", "div", "10", "b = input.read()", "b", "input.read()", "input.read", "input", "return sign * ret / div;", "sign * ret / div", "sign * ret", "sign", "ret", "div", "public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }", "nextChar", "{\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }", "try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }", "catch (IOException e) {\n e.printStackTrace();\n return 0;\n }", "IOException e", "{\n e.printStackTrace();\n return 0;\n }", "e.printStackTrace()", "e.printStackTrace", "e", "return 0;", "0", "{\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n }", "int b = input.read();", "b", "input.read()", "input.read", "input", "while (Character.isWhitespace(b)) {\n b = input.read();\n }", "Character.isWhitespace(b)", "Character.isWhitespace", "Character", "b", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "return (char) b;", "(char) b", "public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }", "nextStr", "{\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }", "try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }", "catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }", "IOException e", "{\n e.printStackTrace();\n return \"\";\n }", "e.printStackTrace()", "e.printStackTrace", "e", "return \"\";", "\"\"", "{\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n }", "StringBuilder sb = new StringBuilder();", "sb", "new StringBuilder()", "int b = input.read();", "b", "input.read()", "input.read", "input", "while (Character.isWhitespace(b)) {\n b = input.read();\n }", "Character.isWhitespace(b)", "Character.isWhitespace", "Character", "b", "{\n b = input.read();\n }", "b = input.read()", "b", "input.read()", "input.read", "input", "while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }", "b != -1 && !Character.isWhitespace(b)", "b != -1", "b", "-1", "1", "!Character.isWhitespace(b)", "Character.isWhitespace(b)", "Character.isWhitespace", "Character", "b", "{\n sb.append((char) b);\n b = input.read();\n }", "sb.append((char) b)", "sb.append", "sb", "(char) b", "b = input.read()", "b", "input.read()", "input.read", "input", "return sb.toString();", "sb.toString()", "sb.toString", "sb", "public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }", "nextLine", "{\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }", "try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }", "catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }", "IOException e", "{\n e.printStackTrace();\n return \"\";\n }", "e.printStackTrace()", "e.printStackTrace", "e", "return \"\";", "\"\"", "{\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n }", "StringBuilder sb = new StringBuilder();", "sb", "new StringBuilder()", "int b = input.read();", "b", "input.read()", "input.read", "input", "while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }", "b != -1 && b != '\\n'", "b != -1", "b", "-1", "1", "b != '\\n'", "b", "'\\n'", "{\n sb.append((char) b);\n b = input.read();\n }", "sb.append((char) b)", "sb.append", "sb", "(char) b", "b = input.read()", "b", "input.read()", "input.read", "input", "return sb.toString();", "sb.toString()", "sb.toString", "sb", "public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }", "nextIntArray", "{\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }", "int[] res = new int[n];", "res", "new int[n]", "n", "for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i] = nextInt();\n }", "{\n res[i] = nextInt();\n }", "res[i] = nextInt()", "res[i]", "res", "i", "nextInt()", "nextInt", "return res;", "res", "int n", "n", "public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }", "nextIntArrayDec", "{\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }", "int[] res = new int[n];", "res", "new int[n]", "n", "for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i] = nextInt() - 1;\n }", "{\n res[i] = nextInt() - 1;\n }", "res[i] = nextInt() - 1", "res[i]", "res", "i", "nextInt() - 1", "nextInt()", "nextInt", "1", "return res;", "res", "int n", "n", "public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }", "nextIntArray1Index", "{\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }", "int[] res = new int[n + 1];", "res", "new int[n + 1]", "n + 1", "n", "1", "for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i + 1] = nextInt();\n }", "{\n res[i + 1] = nextInt();\n }", "res[i + 1] = nextInt()", "res[i + 1]", "res", "i + 1", "i", "1", "nextInt()", "nextInt", "return res;", "res", "int n", "n", "public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }", "nextLongArray", "{\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }", "long[] res = new long[n];", "res", "new long[n]", "n", "for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i] = nextLong();\n }", "{\n res[i] = nextLong();\n }", "res[i] = nextLong()", "res[i]", "res", "i", "nextLong()", "nextLong", "return res;", "res", "int n", "n", "public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }", "nextLongArrayDec", "{\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }", "long[] res = new long[n];", "res", "new long[n]", "n", "for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i] = nextLong() - 1;\n }", "{\n res[i] = nextLong() - 1;\n }", "res[i] = nextLong() - 1", "res[i]", "res", "i", "nextLong() - 1", "nextLong()", "nextLong", "1", "return res;", "res", "int n", "n", "public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }", "nextLongArray1Index", "{\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }", "long[] res = new long[n + 1];", "res", "new long[n + 1]", "n + 1", "n", "1", "for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i + 1] = nextLong();\n }", "{\n res[i + 1] = nextLong();\n }", "res[i + 1] = nextLong()", "res[i + 1]", "res", "i + 1", "i", "1", "nextLong()", "nextLong", "return res;", "res", "int n", "n", "public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }", "nextDoubleArray", "{\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }", "double[] res = new double[n];", "res", "new double[n]", "n", "for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n res[i] = nextDouble();\n }", "{\n res[i] = nextDouble();\n }", "res[i] = nextDouble()", "res[i]", "res", "i", "nextDouble()", "nextDouble", "return res;", "res", "int n", "n", "public class Main {\n FastScanner in;\n PrintWriter out;\n final static int MOD = (int)1e9+7;\n final static long INF = Long.MAX_VALUE / 2;\n \n void solve(){\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }\n \n public static void main(String[] args) {\n new Main().m();\n }\n \n private void m() {\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }\n \n static class FastScanner {\n private Reader input;\n \n public FastScanner() {this(System.in);}\n public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}\n public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n \n public int nextInt() {return (int) nextLong();}\n \n public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }\n \n public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }\n \n public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }\n \n public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }\n \n public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }\n \n public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }\n \n public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }\n \n public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }\n \n public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }\n \n public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }\n }\n}", "public class Main {\n FastScanner in;\n PrintWriter out;\n final static int MOD = (int)1e9+7;\n final static long INF = Long.MAX_VALUE / 2;\n \n void solve(){\n int[] a = in.nextIntArray(3);\n int[] b = new int[]{1, 0, -1};\n int K = in.nextInt();\n long sum = 0;\n for(int i = 0; i < 3; i++){\n long k = Math.min(a[i], K);\n K -= k;\n sum += b[i] * k;\n }\n out.println(sum);\n }\n \n public static void main(String[] args) {\n new Main().m();\n }\n \n private void m() {\n in = new FastScanner(System.in);\n out = new PrintWriter(System.out);\n /*\n try {\n String path = \"input.txt\";\n out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path))));\n }catch (IOException e){\n e.printStackTrace();\n }\n */\n solve();\n out.flush();\n in.close();\n out.close();\n }\n \n static class FastScanner {\n private Reader input;\n \n public FastScanner() {this(System.in);}\n public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));}\n public void close() {\n try {\n this.input.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n \n public int nextInt() {return (int) nextLong();}\n \n public long nextLong() {\n try {\n int sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n long ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) return ret * sign;\n ret *= 10;\n ret += b - '0';\n }\n } catch (IOException e) {\n e.printStackTrace();\n return -1;\n }\n }\n \n public double nextDouble() {\n try {\n double sign = 1;\n int b = input.read();\n while ((b < '0' || '9' < b) && b != '-' && b != '+') {\n b = input.read();\n }\n if (b == '-') {\n sign = -1;\n b = input.read();\n } else if (b == '+') {\n b = input.read();\n }\n double ret = b - '0';\n while (true) {\n b = input.read();\n if (b < '0' || '9' < b) break;\n ret *= 10;\n ret += b - '0';\n }\n if (b != '.') return sign * ret;\n double div = 1;\n b = input.read();\n while ('0' <= b && b <= '9') {\n ret *= 10;\n ret += b - '0';\n div *= 10;\n b = input.read();\n }\n return sign * ret / div;\n } catch (IOException e) {\n e.printStackTrace();\n return Double.NaN;\n }\n }\n \n public char nextChar() {\n try {\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n return (char) b;\n } catch (IOException e) {\n e.printStackTrace();\n return 0;\n }\n }\n \n public String nextStr() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (Character.isWhitespace(b)) {\n b = input.read();\n }\n while (b != -1 && !Character.isWhitespace(b)) {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public String nextLine() {\n try {\n StringBuilder sb = new StringBuilder();\n int b = input.read();\n while (b != -1 && b != '\\n') {\n sb.append((char) b);\n b = input.read();\n }\n return sb.toString();\n } catch (IOException e) {\n e.printStackTrace();\n return \"\";\n }\n }\n \n public int[] nextIntArray(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt();\n }\n return res;\n }\n \n public int[] nextIntArrayDec(int n) {\n int[] res = new int[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextInt() - 1;\n }\n return res;\n }\n \n public int[] nextIntArray1Index(int n) {\n int[] res = new int[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextInt();\n }\n return res;\n }\n \n public long[] nextLongArray(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong();\n }\n return res;\n }\n \n public long[] nextLongArrayDec(int n) {\n long[] res = new long[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextLong() - 1;\n }\n return res;\n }\n \n public long[] nextLongArray1Index(int n) {\n long[] res = new long[n + 1];\n for (int i = 0; i < n; i++) {\n res[i + 1] = nextLong();\n }\n return res;\n }\n \n public double[] nextDoubleArray(int n) {\n double[] res = new double[n];\n for (int i = 0; i < n; i++) {\n res[i] = nextDouble();\n }\n return res;\n }\n }\n}", "Main" ]
import jdk.nashorn.api.scripting.ScriptObjectMirror; import java.io.*; import java.util.*; @SuppressWarnings("unused") public class Main { FastScanner in; PrintWriter out; final static int MOD = (int)1e9+7; final static long INF = Long.MAX_VALUE / 2; void solve(){ int[] a = in.nextIntArray(3); int[] b = new int[]{1, 0, -1}; int K = in.nextInt(); long sum = 0; for(int i = 0; i < 3; i++){ long k = Math.min(a[i], K); K -= k; sum += b[i] * k; } out.println(sum); } public static void main(String[] args) { new Main().m(); } private void m() { in = new FastScanner(System.in); out = new PrintWriter(System.out); /* try { String path = "input.txt"; out = new PrintWriter(new BufferedWriter(new FileWriter(new File(path)))); }catch (IOException e){ e.printStackTrace(); } */ solve(); out.flush(); in.close(); out.close(); } static class FastScanner { private Reader input; public FastScanner() {this(System.in);} public FastScanner(InputStream stream) {this.input = new BufferedReader(new InputStreamReader(stream));} public void close() { try { this.input.close(); } catch (IOException e) { e.printStackTrace(); } } public int nextInt() {return (int) nextLong();} public long nextLong() { try { int sign = 1; int b = input.read(); while ((b < '0' || '9' < b) && b != '-' && b != '+') { b = input.read(); } if (b == '-') { sign = -1; b = input.read(); } else if (b == '+') { b = input.read(); } long ret = b - '0'; while (true) { b = input.read(); if (b < '0' || '9' < b) return ret * sign; ret *= 10; ret += b - '0'; } } catch (IOException e) { e.printStackTrace(); return -1; } } public double nextDouble() { try { double sign = 1; int b = input.read(); while ((b < '0' || '9' < b) && b != '-' && b != '+') { b = input.read(); } if (b == '-') { sign = -1; b = input.read(); } else if (b == '+') { b = input.read(); } double ret = b - '0'; while (true) { b = input.read(); if (b < '0' || '9' < b) break; ret *= 10; ret += b - '0'; } if (b != '.') return sign * ret; double div = 1; b = input.read(); while ('0' <= b && b <= '9') { ret *= 10; ret += b - '0'; div *= 10; b = input.read(); } return sign * ret / div; } catch (IOException e) { e.printStackTrace(); return Double.NaN; } } public char nextChar() { try { int b = input.read(); while (Character.isWhitespace(b)) { b = input.read(); } return (char) b; } catch (IOException e) { e.printStackTrace(); return 0; } } public String nextStr() { try { StringBuilder sb = new StringBuilder(); int b = input.read(); while (Character.isWhitespace(b)) { b = input.read(); } while (b != -1 && !Character.isWhitespace(b)) { sb.append((char) b); b = input.read(); } return sb.toString(); } catch (IOException e) { e.printStackTrace(); return ""; } } public String nextLine() { try { StringBuilder sb = new StringBuilder(); int b = input.read(); while (b != -1 && b != '\n') { sb.append((char) b); b = input.read(); } return sb.toString(); } catch (IOException e) { e.printStackTrace(); return ""; } } public int[] nextIntArray(int n) { int[] res = new int[n]; for (int i = 0; i < n; i++) { res[i] = nextInt(); } return res; } public int[] nextIntArrayDec(int n) { int[] res = new int[n]; for (int i = 0; i < n; i++) { res[i] = nextInt() - 1; } return res; } public int[] nextIntArray1Index(int n) { int[] res = new int[n + 1]; for (int i = 0; i < n; i++) { res[i + 1] = nextInt(); } return res; } public long[] nextLongArray(int n) { long[] res = new long[n]; for (int i = 0; i < n; i++) { res[i] = nextLong(); } return res; } public long[] nextLongArrayDec(int n) { long[] res = new long[n]; for (int i = 0; i < n; i++) { res[i] = nextLong() - 1; } return res; } public long[] nextLongArray1Index(int n) { long[] res = new long[n + 1]; for (int i = 0; i < n; i++) { res[i + 1] = nextLong(); } return res; } public double[] nextDoubleArray(int n) { double[] res = new double[n]; for (int i = 0; i < n; i++) { res[i] = nextDouble(); } return res; } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 0, 13, 13, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 80, 5 ], [ 80, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 40, 45 ], [ 39, 46 ], [ 8, 47 ], [ 47, 48 ], [ 47, 49 ], [ 8, 50 ], [ 50, 51 ], [ 50, 52 ], [ 8, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 58, 63 ], [ 57, 64 ], [ 8, 65 ], [ 65, 66 ], [ 65, 67 ], [ 8, 68 ], [ 68, 69 ], [ 68, 70 ], [ 8, 71 ], [ 71, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 71, 76 ], [ 6, 77 ], [ 77, 78 ], [ 0, 79 ], [ 79, 80 ], [ 79, 81 ] ]
[ "import java.util.*;\n\npublic class Main{\n public static void main(String[] args){\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main{\n public static void main(String[] args){\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }\n}", "Main", "public static void main(String[] args){\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }", "main", "{\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int a = scan.nextInt();", "a", "scan.nextInt()", "scan.nextInt", "scan", "int b = scan.nextInt();", "b", "scan.nextInt()", "scan.nextInt", "scan", "int c = scan.nextInt();", "c", "scan.nextInt()", "scan.nextInt", "scan", "int d = scan.nextInt();", "d", "scan.nextInt()", "scan.nextInt", "scan", "int sum = 0;", "sum", "0", "if (d<=a){\n System.out.println(d);\n return;\n }", "d<=a", "d", "a", "{\n System.out.println(d);\n return;\n }", "System.out.println(d)", "System.out.println", "System.out", "System", "System.out", "d", "return;", "sum = a", "sum", "a", "d -= a", "d", "a", "if(d<=b){\n System.out.println(sum);\n return;\n }", "d<=b", "d", "b", "{\n System.out.println(sum);\n return;\n }", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "return;", "d-=b", "d", "b", "sum -= d", "sum", "d", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main{\n public static void main(String[] args){\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }\n}", "public class Main{\n public static void main(String[] args){\n Scanner scan = new Scanner(System.in);\n int a = scan.nextInt();\n int b = scan.nextInt();\n int c = scan.nextInt();\n int d = scan.nextInt();\n int sum = 0;\n if (d<=a){\n System.out.println(d);\n return;\n }\n sum = a;\n d -= a;\n if(d<=b){\n System.out.println(sum);\n return;\n }\n d-=b;\n sum -= d;\n System.out.println(sum);\n }\n}", "Main" ]
import java.util.*; public class Main{ public static void main(String[] args){ Scanner scan = new Scanner(System.in); int a = scan.nextInt(); int b = scan.nextInt(); int c = scan.nextInt(); int d = scan.nextInt(); int sum = 0; if (d<=a){ System.out.println(d); return; } sum = a; d -= a; if(d<=b){ System.out.println(sum); return; } d-=b; sum -= d; System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 13, 41, 13, 13, 41, 13, 13, 41, 13, 17, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 2, 13, 17, 2, 13, 17, 30, 3, 30, 40, 13, 40, 13, 40, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 2, 13, 17, 2, 13, 17, 30, 3, 30, 40, 13, 40, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 2, 13, 17, 2, 13, 17, 30, 3, 30, 40, 13, 40, 13, 40, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 144, 5 ], [ 144, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 8, 41 ], [ 41, 42 ], [ 41, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 47, 52 ], [ 52, 53 ], [ 52, 54 ], [ 47, 55 ], [ 55, 56 ], [ 56, 57 ], [ 47, 58 ], [ 59, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 65, 67 ], [ 60, 68 ], [ 68, 69 ], [ 60, 70 ], [ 70, 71 ], [ 71, 72 ], [ 70, 73 ], [ 73, 74 ], [ 70, 75 ], [ 75, 76 ], [ 8, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 82, 83 ], [ 82, 84 ], [ 77, 85 ], [ 85, 86 ], [ 86, 87 ], [ 77, 88 ], [ 89, 89 ], [ 89, 90 ], [ 90, 91 ], [ 91, 92 ], [ 92, 93 ], [ 92, 94 ], [ 91, 95 ], [ 95, 96 ], [ 95, 97 ], [ 90, 98 ], [ 98, 99 ], [ 90, 100 ], [ 100, 101 ], [ 101, 102 ], [ 100, 103 ], [ 103, 104 ], [ 8, 105 ], [ 105, 106 ], [ 106, 107 ], [ 107, 108 ], [ 107, 109 ], [ 105, 110 ], [ 110, 111 ], [ 110, 112 ], [ 105, 113 ], [ 113, 114 ], [ 114, 115 ], [ 105, 116 ], [ 117, 117 ], [ 117, 118 ], [ 118, 119 ], [ 119, 120 ], [ 120, 121 ], [ 120, 122 ], [ 119, 123 ], [ 123, 124 ], [ 123, 125 ], [ 118, 126 ], [ 126, 127 ], [ 118, 128 ], [ 128, 129 ], [ 129, 130 ], [ 128, 131 ], [ 131, 132 ], [ 128, 133 ], [ 133, 134 ], [ 8, 135 ], [ 135, 136 ], [ 136, 137 ], [ 137, 138 ], [ 137, 139 ], [ 135, 140 ], [ 6, 141 ], [ 141, 142 ], [ 0, 143 ], [ 143, 144 ], [ 143, 145 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}", "main", "{\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int tmp_a = a;", "tmp_a", "a", "int tmp_b = b;", "tmp_b", "b", "int tmp_c = c;", "tmp_c", "c", "int ans = 0;", "ans", "0", "sc.close()", "sc.close", "sc", "for (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "i < tmp_a", "i", "tmp_a", "i++", "i++", "i", "{\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}", "{\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}", "if (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}", "k == 0 || a == 0", "k == 0", "k", "0", "a == 0", "a", "0", "{\n\t\t\t\tbreak;\n\t\t\t}", "break;", "{\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}", "ans ++", "ans", "k --", "k", "a --", "a", "for (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "i < tmp_b", "i", "tmp_b", "i++", "i++", "i", "{\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}", "{\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}", "if (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}", "k == 0 || b == 0", "k == 0", "k", "0", "b == 0", "b", "0", "{\n\t\t\t\tbreak;\n\t\t\t}", "break;", "{\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}", "k --", "k", "b --", "b", "for (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}", "int i = 0;", "int i = 0;", "i", "0", "i < tmp_c", "i", "tmp_c", "i++", "i++", "i", "{\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}", "{\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}", "if (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}", "k == 0 || c == 0", "k == 0", "k", "0", "c == 0", "c", "0", "{\n\t\t\t\tbreak;\n\t\t\t}", "break;", "{\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}", "ans --", "ans", "k --", "k", "c --", "c", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\n\t\tint tmp_a = a;\n\t\tint tmp_b = b;\n\t\tint tmp_c = c;\n\n\t\tint ans = 0;\n\t\tsc.close();\n\n\t\tfor (int i = 0; i < tmp_a; i++) {\n\t\t\tif (k == 0 || a == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans ++;\n\t\t\t\tk --;\n\t\t\t\ta --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_b; i++) {\n\t\t\tif (k == 0 || b == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tk --;\n\t\t\t\tb --;\n\t\t\t}\n\t\t}\n\n\n\t\tfor (int i = 0; i < tmp_c; i++) {\n\t\t\tif (k == 0 || c == 0) {\n\t\t\t\tbreak;\n\t\t\t} else {\n\t\t\t\tans --;\n\t\t\t\tk --;\n\t\t\t\tc --;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { // TODO 自動生成されたメソッド・スタブ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int tmp_a = a; int tmp_b = b; int tmp_c = c; int ans = 0; sc.close(); for (int i = 0; i < tmp_a; i++) { if (k == 0 || a == 0) { break; } else { ans ++; k --; a --; } } for (int i = 0; i < tmp_b; i++) { if (k == 0 || b == 0) { break; } else { k --; b --; } } for (int i = 0; i < tmp_c; i++) { if (k == 0 || c == 0) { break; } else { ans --; k --; c --; } } System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 2, 13, 13, 2, 13, 2, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 30, 41, 13, 2, 13, 2, 13, 13, 0, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 77, 5 ], [ 77, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 36, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 42, 44 ], [ 35, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 45, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 49, 54 ], [ 35, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 60, 62 ], [ 55, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 65, 67 ], [ 55, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 6, 74 ], [ 74, 75 ], [ 0, 76 ], [ 76, 77 ], [ 76, 78 ] ]
[ "import java.util.*;\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}", "main", "{\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}", "Scanner in=new Scanner (System.in);", "in", "new Scanner (System.in)", "int A=in.nextInt();", "A", "in.nextInt()", "in.nextInt", "in", "int B=in.nextInt();", "B", "in.nextInt()", "in.nextInt", "in", "int C=in.nextInt();", "C", "in.nextInt()", "in.nextInt", "in", "int K=in.nextInt();", "K", "in.nextInt()", "in.nextInt", "in", "int sum=0;", "sum", "0", "if (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}", "K<=A && K<=(A+B)", "K<=A", "K", "A", "K<=(A+B)", "K", "(A+B)", "A", "B", "{\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}", "sum=K", "sum", "K", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "{\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}", "int s =K-(A+B);", "s", "K-(A+B)", "K", "(A+B)", "A", "B", "sum =A-s", "sum", "A-s", "A", "s", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner in=new Scanner (System.in);\n\t\tint A=in.nextInt();\n\t\tint B=in.nextInt();\n\t\tint C=in.nextInt();\n\t\tint K=in.nextInt();\n\t\tint sum=0;\n\t\tif (K<=A && K<=(A+B)) {\n\t\t\tsum=K;\n\t\t\tSystem.out.println(sum);\n\t\t}else {\n\t\t\tint s =K-(A+B);\n\t\t\tsum =A-s;\n\t\t\tSystem.out.println(sum);\n\t\t\t\n\t\t}\n\t}\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner in=new Scanner (System.in); int A=in.nextInt(); int B=in.nextInt(); int C=in.nextInt(); int K=in.nextInt(); int sum=0; if (K<=A && K<=(A+B)) { sum=K; System.out.println(sum); }else { int s =K-(A+B); sum =A-s; System.out.println(sum); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 20, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 0, 13, 13, 0, 13, 2, 13, 13, 14, 2, 13, 17, 4, 18, 18, 13, 13, 4, 18, 13, 13, 13, 14, 2, 13, 17, 30, 0, 13, 13, 14, 2, 13, 17, 4, 18, 18, 13, 13, 2, 13, 13, 14, 2, 13, 17, 30, 0, 13, 2, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 23, 13, 23, 13, 12, 13, 30, 29, 2, 2, 13, 17, 2, 13, 17, 12, 13, 30, 14, 2, 36, 13, 29, 17, 14, 2, 13, 13, 30, 41, 13, 13, 29, 2, 2, 18, 13, 13, 18, 36, 13, 2, 18, 13, 13, 18, 36, 13, 29, 17, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 18, 13, 13, 18, 13, 13, 41, 13, 2, 18, 13, 13, 18, 13, 13, 29, 2, 18, 13, 13, 18, 13, 13, 23, 13, 23, 13, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 22, 23 ], [ 22, 24 ], [ 0, 25 ], [ 25, 26 ], [ 25, 27 ], [ 0, 28 ], [ 28, 29 ], [ 28, 30 ], [ 0, 31 ], [ 31, 32 ], [ 31, 33 ], [ 0, 34 ], [ 34, 35 ], [ 34, 36 ], [ 0, 37 ], [ 37, 38 ], [ 37, 39 ], [ 0, 40 ], [ 40, 41 ], [ 40, 42 ], [ 0, 43 ], [ 43, 44 ], [ 43, 45 ], [ 0, 46 ], [ 46, 47 ], [ 46, 48 ], [ 0, 49 ], [ 265, 50 ], [ 265, 51 ], [ 51, 52 ], [ 51, 53 ], [ 265, 54 ], [ 54, 55 ], [ 54, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 56, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 65, 66 ], [ 56, 67 ], [ 67, 68 ], [ 67, 69 ], [ 69, 70 ], [ 70, 71 ], [ 56, 72 ], [ 72, 73 ], [ 72, 74 ], [ 74, 75 ], [ 75, 76 ], [ 56, 77 ], [ 77, 78 ], [ 77, 79 ], [ 56, 80 ], [ 80, 81 ], [ 80, 82 ], [ 56, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 85, 87 ], [ 56, 88 ], [ 88, 89 ], [ 89, 90 ], [ 89, 91 ], [ 88, 92 ], [ 92, 93 ], [ 93, 94 ], [ 94, 95 ], [ 94, 96 ], [ 92, 97 ], [ 97, 98 ], [ 98, 99 ], [ 97, 100 ], [ 97, 101 ], [ 88, 102 ], [ 102, 103 ], [ 103, 104 ], [ 103, 105 ], [ 102, 106 ], [ 106, 107 ], [ 107, 108 ], [ 107, 109 ], [ 106, 110 ], [ 110, 111 ], [ 111, 112 ], [ 111, 113 ], [ 110, 114 ], [ 114, 115 ], [ 115, 116 ], [ 116, 117 ], [ 116, 118 ], [ 114, 119 ], [ 119, 120 ], [ 119, 121 ], [ 110, 122 ], [ 122, 123 ], [ 123, 124 ], [ 123, 125 ], [ 122, 126 ], [ 126, 127 ], [ 127, 128 ], [ 127, 129 ], [ 129, 130 ], [ 129, 131 ], [ 126, 132 ], [ 132, 133 ], [ 133, 134 ], [ 134, 135 ], [ 134, 136 ], [ 132, 137 ], [ 137, 138 ], [ 137, 139 ], [ 122, 140 ], [ 140, 141 ], [ 141, 142 ], [ 141, 143 ], [ 140, 144 ], [ 144, 145 ], [ 145, 146 ], [ 146, 147 ], [ 147, 148 ], [ 147, 149 ], [ 145, 150 ], [ 150, 151 ], [ 150, 152 ], [ 54, 153 ], [ 153, 154 ], [ 0, 155 ], [ 155, 156 ], [ 155, 157 ], [ 157, 158 ], [ 155, 159 ], [ 159, 160 ], [ 155, 161 ], [ 161, 162 ], [ 161, 163 ], [ 163, 164 ], [ 164, 165 ], [ 165, 166 ], [ 165, 167 ], [ 164, 168 ], [ 163, 169 ], [ 169, 170 ], [ 170, 171 ], [ 170, 172 ], [ 169, 173 ], [ 161, 174 ], [ 174, 175 ], [ 161, 176 ], [ 176, 177 ], [ 155, 178 ], [ 178, 179 ], [ 178, 180 ], [ 180, 181 ], [ 181, 182 ], [ 182, 183 ], [ 183, 184 ], [ 183, 185 ], [ 182, 186 ], [ 186, 187 ], [ 186, 188 ], [ 155, 189 ], [ 189, 190 ], [ 189, 191 ], [ 191, 192 ], [ 192, 193 ], [ 193, 194 ], [ 193, 195 ], [ 192, 196 ], [ 196, 197 ], [ 191, 198 ], [ 198, 199 ], [ 199, 200 ], [ 199, 201 ], [ 198, 202 ], [ 202, 203 ], [ 203, 204 ], [ 203, 205 ], [ 202, 206 ], [ 206, 207 ], [ 207, 208 ], [ 208, 209 ], [ 209, 210 ], [ 209, 211 ], [ 208, 212 ], [ 212, 213 ], [ 212, 214 ], [ 207, 215 ], [ 215, 216 ], [ 216, 217 ], [ 216, 218 ], [ 215, 219 ], [ 219, 220 ], [ 219, 221 ], [ 198, 222 ], [ 222, 223 ], [ 189, 224 ], [ 224, 225 ], [ 0, 226 ], [ 226, 227 ], [ 226, 228 ], [ 228, 229 ], [ 228, 230 ], [ 230, 231 ], [ 231, 232 ], [ 231, 233 ], [ 233, 234 ], [ 234, 235 ], [ 233, 236 ], [ 236, 237 ], [ 236, 238 ], [ 233, 239 ], [ 239, 240 ], [ 239, 241 ], [ 230, 242 ], [ 242, 243 ], [ 242, 244 ], [ 244, 245 ], [ 245, 246 ], [ 245, 247 ], [ 244, 248 ], [ 248, 249 ], [ 248, 250 ], [ 230, 251 ], [ 251, 252 ], [ 252, 253 ], [ 253, 254 ], [ 253, 255 ], [ 252, 256 ], [ 256, 257 ], [ 256, 258 ], [ 228, 259 ], [ 259, 260 ], [ 228, 261 ], [ 261, 262 ], [ 226, 263 ], [ 0, 264 ], [ 264, 265 ], [ 264, 266 ] ]
[ "//package codeforces;\n\nimport java.util.Scanner;\nimport java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.StringTokenizer;\nimport java.util.HashMap;\nimport java.util.HashSet;\nimport java.util.Iterator;\nimport java.util.TreeMap;\nimport java.util.TreeSet;\nimport java.math.BigInteger;\nimport java.util.ArrayList;\nimport java.util.Arrays;\nimport java.util.Collections;\nimport java.util.Comparator;\nimport java.util.Stack;\n\npublic class Main {\n\t// Integer.bitCount(i); count no of 1 bit in a given number\n\tstatic Scanner scn = new Scanner(System.in);\n//\tstatic class FastReader {\n//\tBufferedReader br;\n//\tStringTokenizer st;\n//\n//\tpublic FastReader() {\n//\t\tbr = new BufferedReader(new InputStreamReader(System.in));\n//\t}\n//\n//\tString next() {\n//\t\twhile (st == null || !st.hasMoreElements()) {\n//\t\t\ttry {\n//\t\t\t\tst = new StringTokenizer(br.readLine());\n//\t\t\t} catch (IOException e) {\n//\t\t\t\te.printStackTrace();\n//\t\t\t}\n//\t\t}\n//\t\treturn st.nextToken();\n//\t}\n//\n//\tint nextInt() {\n//\t\treturn Integer.parseInt(next());\n//\t}\n//\n//\tlong nextLong() {\n//\t\treturn Long.parseLong(next());\n//\t}\n//\n//\tdouble nextDouble() {\n//\t\treturn Double.parseDouble(next());\n//\t}\n//\n//\tString nextLine() {\n//\t\tString str = \"\";\n//\t\ttry {\n//\t\t\tstr = br.readLine();\n//\t\t} catch (IOException e) {\n//\t\t\te.printStackTrace();\n//\t\t}\n//\t\treturn str;\n//\t}\n//}\n//\n//static FastReader s = new FastReader();\n\t\n\n\t\n\tpublic static void main(String[] args) {\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}\n}\n\tclass pair\n\t{\n\t\tint x;\n\t\tint y;\n\t\t\n\t\tpair(int a,int b)\n\t\t{\n\t\t\tthis.x=a;\n\t\t\tthis.y=b;\n\t\t\t\n\t\t}\n\t\tpublic int hashCode()\n\t\t {\n\t\t return x*31+y*31;\n\t\t }\n\t\t \n\t\t public boolean equals(Object other)\n\t\t {\n\t\t if(this==other) return true;\n\t\t \n\t\t if(other instanceof pair)\n\t\t {\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }\n\t\t else return false;\n\t\t }\n\t}\n\tclass sorting implements Comparator<pair>\n\t{\n\n\t\t@Override\n\t\tpublic int compare(pair o1, pair o2) {\n\t\t\t// TODO Auto-generated method stub\n\t\t\tint a=Math.max(o1.x,o2.x),b=o1.y-o2.y;\n\t\t\treturn o1.x-o2.x;\n\t\t}\n\t\t\n\t}\n", "import java.util.Scanner;", "Scanner", "java.util", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.util.StringTokenizer;", "StringTokenizer", "java.util", "import java.util.HashMap;", "HashMap", "java.util", "import java.util.HashSet;", "HashSet", "java.util", "import java.util.Iterator;", "Iterator", "java.util", "import java.util.TreeMap;", "TreeMap", "java.util", "import java.util.TreeSet;", "TreeSet", "java.util", "import java.math.BigInteger;", "BigInteger", "java.math", "import java.util.ArrayList;", "ArrayList", "java.util", "import java.util.Arrays;", "Arrays", "java.util", "import java.util.Collections;", "Collections", "java.util", "import java.util.Comparator;", "Comparator", "java.util", "import java.util.Stack;", "Stack", "java.util", "public class Main {\n\t// Integer.bitCount(i); count no of 1 bit in a given number\n\tstatic Scanner scn = new Scanner(System.in);\n//\tstatic class FastReader {\n//\tBufferedReader br;\n//\tStringTokenizer st;\n//\n//\tpublic FastReader() {\n//\t\tbr = new BufferedReader(new InputStreamReader(System.in));\n//\t}\n//\n//\tString next() {\n//\t\twhile (st == null || !st.hasMoreElements()) {\n//\t\t\ttry {\n//\t\t\t\tst = new StringTokenizer(br.readLine());\n//\t\t\t} catch (IOException e) {\n//\t\t\t\te.printStackTrace();\n//\t\t\t}\n//\t\t}\n//\t\treturn st.nextToken();\n//\t}\n//\n//\tint nextInt() {\n//\t\treturn Integer.parseInt(next());\n//\t}\n//\n//\tlong nextLong() {\n//\t\treturn Long.parseLong(next());\n//\t}\n//\n//\tdouble nextDouble() {\n//\t\treturn Double.parseDouble(next());\n//\t}\n//\n//\tString nextLine() {\n//\t\tString str = \"\";\n//\t\ttry {\n//\t\t\tstr = br.readLine();\n//\t\t} catch (IOException e) {\n//\t\t\te.printStackTrace();\n//\t\t}\n//\t\treturn str;\n//\t}\n//}\n//\n//static FastReader s = new FastReader();\n\t\n\n\t\n\tpublic static void main(String[] args) {\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}\n}", "Main", "// Integer.bitCount(i); count no of 1 bit in a given number\n\tstatic Scanner scn = new Scanner(System.in);", "scn", "new Scanner(System.in)", "public static void main(String[] args) {\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}", "main", "{\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}", "long a=scn.nextLong()", "a", "scn.nextLong()", "scn.nextLong", "scn", "b=scn.nextLong()", "b", "scn.nextLong()", "scn.nextLong", "scn", "c=scn.nextLong()", "c", "scn.nextLong()", "scn.nextLong", "scn", "k=scn.nextLong()", "k", "scn.nextLong()", "scn.nextLong", "scn", "t=0;", "t", "0", "t=k", "t", "k", "k-=(a+b)", "k", "(a+b)", "a", "b", "if(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}", "k<=0", "k", "0", "System.out.println(Math.min(a,t))", "System.out.println", "System.out", "System", "System.out", "Math.min(a,t)", "Math.min", "Math", "a", "t", "if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}", "k>0", "k", "0", "{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}", "k-=c", "k", "c", "if(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}", "k==0", "k", "0", "System.out.println(a-c)", "System.out.println", "System.out", "System", "System.out", "a-c", "a", "c", "if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}", "k<0", "k", "0", "{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}", "t-=(a+b)", "t", "(a+b)", "a", "b", "System.out.println(a-t)", "System.out.println", "System.out", "System", "System.out", "a-t", "a", "t", "if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}", "k>0", "k", "0", "{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}", "System.out.println(a-c)", "System.out.println", "System.out", "System", "System.out", "a-c", "a", "c", "String[] args", "args", "class pair\n\t{\n\t\tint x;\n\t\tint y;\n\t\t\n\t\tpair(int a,int b)\n\t\t{\n\t\t\tthis.x=a;\n\t\t\tthis.y=b;\n\t\t\t\n\t\t}\n\t\tpublic int hashCode()\n\t\t {\n\t\t return x*31+y*31;\n\t\t }\n\t\t \n\t\t public boolean equals(Object other)\n\t\t {\n\t\t if(this==other) return true;\n\t\t \n\t\t if(other instanceof pair)\n\t\t {\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }\n\t\t else return false;\n\t\t }\n\t}", "pair", "int x;", "x", "int y;", "y", "pair(int a,int b)\n\t\t{\n\t\t\tthis.x=a;\n\t\t\tthis.y=b;\n\t\t\t\n\t\t}", "pair", "{\n\t\t\tthis.x=a;\n\t\t\tthis.y=b;\n\t\t\t\n\t\t}", "this.x=a", "this.x", "this", "this.x", "a", "this.y=b", "this.y", "this", "this.y", "b", "int a", "a", "int b", "b", "public int hashCode()\n\t\t {\n\t\t return x*31+y*31;\n\t\t }", "hashCode", "{\n\t\t return x*31+y*31;\n\t\t }", "return x*31+y*31;", "x*31+y*31", "x*31", "x", "31", "y*31", "y", "31", "public boolean equals(Object other)\n\t\t {\n\t\t if(this==other) return true;\n\t\t \n\t\t if(other instanceof pair)\n\t\t {\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }\n\t\t else return false;\n\t\t }", "equals", "{\n\t\t if(this==other) return true;\n\t\t \n\t\t if(other instanceof pair)\n\t\t {\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }\n\t\t else return false;\n\t\t }", "if(this==other) return true;", "this==other", "this", "other", "return true;", "true", "if(other instanceof pair)\n\t\t {\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }\n\t\t else return false;", "other instanceof pair", "other", "pair", "{\n\t\t pair pt = (pair)other;\n\t\t \n\t\t return pt.x==this.x && pt.y==this.y;\n\t\t }", "pair pt = (pair)other;", "pt", "(pair)other", "return pt.x==this.x && pt.y==this.y;", "pt.x==this.x && pt.y==this.y", "pt.x==this.x", "pt.x", "pt", "pt.x", "this.x", "this", "this.x", "pt.y==this.y", "pt.y", "pt", "pt.y", "this.y", "this", "this.y", "return false;", "false", "Object other", "other", "class sorting implements Comparator<pair>\n\t{\n\n\t\t@Override\n\t\tpublic int compare(pair o1, pair o2) {\n\t\t\t// TODO Auto-generated method stub\n\t\t\tint a=Math.max(o1.x,o2.x),b=o1.y-o2.y;\n\t\t\treturn o1.x-o2.x;\n\t\t}\n\t\t\n\t}", "sorting", "@Override\n\t\tpublic int compare(pair o1, pair o2) {\n\t\t\t// TODO Auto-generated method stub\n\t\t\tint a=Math.max(o1.x,o2.x),b=o1.y-o2.y;\n\t\t\treturn o1.x-o2.x;\n\t\t}", "compare", "{\n\t\t\t// TODO Auto-generated method stub\n\t\t\tint a=Math.max(o1.x,o2.x),b=o1.y-o2.y;\n\t\t\treturn o1.x-o2.x;\n\t\t}", "int a=Math.max(o1.x,o2.x)", "a", "Math.max(o1.x,o2.x)", "Math.max", "Math", "o1.x", "o1", "o1.x", "o2.x", "o2", "o2.x", "b=o1.y-o2.y;", "b", "o1.y-o2.y", "o1.y", "o1", "o1.y", "o2.y", "o2", "o2.y", "return o1.x-o2.x;", "o1.x-o2.x", "o1.x", "o1", "o1.x", "o2.x", "o2", "o2.x", "pair o1", "o1", "pair o2", "o2", "Comparator", "public class Main {\n\t// Integer.bitCount(i); count no of 1 bit in a given number\n\tstatic Scanner scn = new Scanner(System.in);\n//\tstatic class FastReader {\n//\tBufferedReader br;\n//\tStringTokenizer st;\n//\n//\tpublic FastReader() {\n//\t\tbr = new BufferedReader(new InputStreamReader(System.in));\n//\t}\n//\n//\tString next() {\n//\t\twhile (st == null || !st.hasMoreElements()) {\n//\t\t\ttry {\n//\t\t\t\tst = new StringTokenizer(br.readLine());\n//\t\t\t} catch (IOException e) {\n//\t\t\t\te.printStackTrace();\n//\t\t\t}\n//\t\t}\n//\t\treturn st.nextToken();\n//\t}\n//\n//\tint nextInt() {\n//\t\treturn Integer.parseInt(next());\n//\t}\n//\n//\tlong nextLong() {\n//\t\treturn Long.parseLong(next());\n//\t}\n//\n//\tdouble nextDouble() {\n//\t\treturn Double.parseDouble(next());\n//\t}\n//\n//\tString nextLine() {\n//\t\tString str = \"\";\n//\t\ttry {\n//\t\t\tstr = br.readLine();\n//\t\t} catch (IOException e) {\n//\t\t\te.printStackTrace();\n//\t\t}\n//\t\treturn str;\n//\t}\n//}\n//\n//static FastReader s = new FastReader();\n\t\n\n\t\n\tpublic static void main(String[] args) {\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}\n}", "public class Main {\n\t// Integer.bitCount(i); count no of 1 bit in a given number\n\tstatic Scanner scn = new Scanner(System.in);\n//\tstatic class FastReader {\n//\tBufferedReader br;\n//\tStringTokenizer st;\n//\n//\tpublic FastReader() {\n//\t\tbr = new BufferedReader(new InputStreamReader(System.in));\n//\t}\n//\n//\tString next() {\n//\t\twhile (st == null || !st.hasMoreElements()) {\n//\t\t\ttry {\n//\t\t\t\tst = new StringTokenizer(br.readLine());\n//\t\t\t} catch (IOException e) {\n//\t\t\t\te.printStackTrace();\n//\t\t\t}\n//\t\t}\n//\t\treturn st.nextToken();\n//\t}\n//\n//\tint nextInt() {\n//\t\treturn Integer.parseInt(next());\n//\t}\n//\n//\tlong nextLong() {\n//\t\treturn Long.parseLong(next());\n//\t}\n//\n//\tdouble nextDouble() {\n//\t\treturn Double.parseDouble(next());\n//\t}\n//\n//\tString nextLine() {\n//\t\tString str = \"\";\n//\t\ttry {\n//\t\t\tstr = br.readLine();\n//\t\t} catch (IOException e) {\n//\t\t\te.printStackTrace();\n//\t\t}\n//\t\treturn str;\n//\t}\n//}\n//\n//static FastReader s = new FastReader();\n\t\n\n\t\n\tpublic static void main(String[] args) {\n\t\t/* TODO Auto-generated method stub */\n\t\t// System.out.format(\"%.10f\", ans);char c = sc.next().charAt(0);\n\t\t\n\t\t\n\t\tlong a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0;\n\t\tt=k;\n\t\tk-=(a+b);\n\t\tif(k<=0)\n\t\t\tSystem.out.println(Math.min(a,t));\n\t\telse if(k>0)\n\t\t{\n\t\t\tk-=c;\n\t\t\tif(k==0)\n\t\t\t\tSystem.out.println(a-c);\n\t\t\telse if(k<0)\n\t\t\t{\tt-=(a+b);\n\t\t\t\n\t\t\t\tSystem.out.println(a-t);\n\t\t\t}\n\t\t\telse if(k>0)\n\t\t\t{\n\t\t\t\tSystem.out.println(a-c);\n\t\t\t}\n\t\t}\n\t\t\n}\n}", "Main" ]
//package codeforces; import java.util.Scanner; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; import java.util.TreeMap; import java.util.TreeSet; import java.math.BigInteger; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.Comparator; import java.util.Stack; public class Main { // Integer.bitCount(i); count no of 1 bit in a given number static Scanner scn = new Scanner(System.in); // static class FastReader { // BufferedReader br; // StringTokenizer st; // // public FastReader() { // br = new BufferedReader(new InputStreamReader(System.in)); // } // // String next() { // while (st == null || !st.hasMoreElements()) { // try { // st = new StringTokenizer(br.readLine()); // } catch (IOException e) { // e.printStackTrace(); // } // } // return st.nextToken(); // } // // int nextInt() { // return Integer.parseInt(next()); // } // // long nextLong() { // return Long.parseLong(next()); // } // // double nextDouble() { // return Double.parseDouble(next()); // } // // String nextLine() { // String str = ""; // try { // str = br.readLine(); // } catch (IOException e) { // e.printStackTrace(); // } // return str; // } //} // //static FastReader s = new FastReader(); public static void main(String[] args) { /* TODO Auto-generated method stub */ // System.out.format("%.10f", ans);char c = sc.next().charAt(0); long a=scn.nextLong(),b=scn.nextLong(),c=scn.nextLong(),k=scn.nextLong(),t=0; t=k; k-=(a+b); if(k<=0) System.out.println(Math.min(a,t)); else if(k>0) { k-=c; if(k==0) System.out.println(a-c); else if(k<0) { t-=(a+b); System.out.println(a-t); } else if(k>0) { System.out.println(a-c); } } } } class pair { int x; int y; pair(int a,int b) { this.x=a; this.y=b; } public int hashCode() { return x*31+y*31; } public boolean equals(Object other) { if(this==other) return true; if(other instanceof pair) { pair pt = (pair)other; return pt.x==this.x && pt.y==this.y; } else return false; } } class sorting implements Comparator<pair> { @Override public int compare(pair o1, pair o2) { // TODO Auto-generated method stub int a=Math.max(o1.x,o2.x),b=o1.y-o2.y; return o1.x-o2.x; } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 41, 13, 41, 13, 41, 13, 41, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 4, 18, 4, 18, 13, 17, 0, 13, 4, 18, 13, 18, 13, 17, 0, 13, 4, 18, 13, 18, 13, 17, 0, 13, 4, 18, 13, 18, 13, 17, 0, 13, 4, 18, 13, 18, 13, 17, 4, 18, 13, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 13, 13, 14, 2, 13, 17, 0, 13, 13, 4, 18, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 103, 11 ], [ 103, 12 ], [ 12, 13 ], [ 103, 14 ], [ 14, 15 ], [ 103, 16 ], [ 16, 17 ], [ 103, 18 ], [ 18, 19 ], [ 103, 20 ], [ 20, 21 ], [ 103, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 25, 27 ], [ 24, 28 ], [ 28, 29 ], [ 28, 30 ], [ 24, 31 ], [ 31, 32 ], [ 31, 33 ], [ 33, 34 ], [ 34, 35 ], [ 35, 36 ], [ 36, 37 ], [ 33, 38 ], [ 24, 39 ], [ 39, 40 ], [ 39, 41 ], [ 41, 42 ], [ 42, 43 ], [ 41, 44 ], [ 44, 45 ], [ 44, 46 ], [ 24, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 50, 51 ], [ 49, 52 ], [ 52, 53 ], [ 52, 54 ], [ 24, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 58, 59 ], [ 57, 60 ], [ 60, 61 ], [ 60, 62 ], [ 24, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 66, 67 ], [ 65, 68 ], [ 68, 69 ], [ 68, 70 ], [ 24, 71 ], [ 71, 72 ], [ 72, 73 ], [ 24, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 77, 78 ], [ 76, 79 ], [ 76, 80 ], [ 24, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 24, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 90, 92 ], [ 24, 93 ], [ 93, 94 ], [ 94, 95 ], [ 93, 96 ], [ 24, 97 ], [ 97, 98 ], [ 98, 99 ], [ 22, 100 ], [ 100, 101 ], [ 0, 102 ], [ 102, 103 ], [ 102, 104 ] ]
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.io.PrintWriter;\n\npublic class Main {\n\n static int a, b, c, k, ans;\n\n public static void main(String[] args) throws Exception {\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "public class Main {\n\n static int a, b, c, k, ans;\n\n public static void main(String[] args) throws Exception {\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }\n}", "Main", "static int a", "a", "b", "b", "c", "c", "k", "k", "ans;", "ans", "public static void main(String[] args) throws Exception {\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }", "main", "{\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }", "BufferedReader br = new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "PrintWriter out = new PrintWriter(System.out);", "out", "new PrintWriter(System.out)", "String[] in = br.readLine().split(\" \");", "in", "br.readLine().split(\" \")", "br.readLine().split", "br.readLine()", "br.readLine", "br", "\" \"", "a = Integer.parseInt(in[0])", "a", "Integer.parseInt(in[0])", "Integer.parseInt", "Integer", "in[0]", "in", "0", "b = Integer.parseInt(in[1])", "b", "Integer.parseInt(in[1])", "Integer.parseInt", "Integer", "in[1]", "in", "1", "c = Integer.parseInt(in[2])", "c", "Integer.parseInt(in[2])", "Integer.parseInt", "Integer", "in[2]", "in", "2", "k = Integer.parseInt(in[3])", "k", "Integer.parseInt(in[3])", "Integer.parseInt", "Integer", "in[3]", "in", "3", "br.close()", "br.close", "br", "ans = Math.min(a, k)", "ans", "Math.min(a, k)", "Math.min", "Math", "a", "k", "k -= a + b", "k", "a + b", "a", "b", "if(k > 0) ans -= k;", "k > 0", "k", "0", "ans -= k", "ans", "k", "out.println(ans)", "out.println", "out", "ans", "out.flush()", "out.flush", "out", "String[] args", "args", "public class Main {\n\n static int a, b, c, k, ans;\n\n public static void main(String[] args) throws Exception {\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }\n}", "public class Main {\n\n static int a, b, c, k, ans;\n\n public static void main(String[] args) throws Exception {\n\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n PrintWriter out = new PrintWriter(System.out);\n\n String[] in = br.readLine().split(\" \");\n a = Integer.parseInt(in[0]);\n b = Integer.parseInt(in[1]);\n c = Integer.parseInt(in[2]);\n k = Integer.parseInt(in[3]);\n\n /*\n =====templates=====\n ===inputs===\n static int n;\n in = br.readLine().split(\" \");\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n int n = Integer.parseInt(in[0]);\n long n = Long.parseLong(in[0]);\n int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray();\n\n ===outputs===\n PrintWriter out = new PrintWriter(System.out);\n out.println(ans);\n out.flush();\n */\n\n br.close();\n\n ans = Math.min(a, k);\n k -= a + b;\n if(k > 0) ans -= k;\n\n out.println(ans);\n\n out.flush();\n\n }\n}", "Main" ]
import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.PrintWriter; public class Main { static int a, b, c, k, ans; public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); PrintWriter out = new PrintWriter(System.out); String[] in = br.readLine().split(" "); a = Integer.parseInt(in[0]); b = Integer.parseInt(in[1]); c = Integer.parseInt(in[2]); k = Integer.parseInt(in[3]); /* =====templates===== ===inputs=== static int n; in = br.readLine().split(" "); int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray(); int n = Integer.parseInt(in[0]); long n = Long.parseLong(in[0]); int[] a = Stream.of(in).mapToInt(Integer::parseInt).toArray(); ===outputs=== PrintWriter out = new PrintWriter(System.out); out.println(ans); out.flush(); */ br.close(); ans = Math.min(a, k); k -= a + b; if(k > 0) ans -= k; out.println(ans); out.flush(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 71, 5 ], [ 71, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 8, 34 ], [ 34, 35 ], [ 35, 36 ], [ 35, 37 ], [ 34, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 34, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 45, 47 ], [ 42, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 42, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 59, 61 ], [ 8, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 6, 68 ], [ 68, 69 ], [ 0, 70 ], [ 70, 71 ], [ 70, 72 ] ]
[ "import java.util.*;\n\npublic class Main {\n public static void main(String[] args) throws Exception {\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args) throws Exception {\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }\n}", "Main", "public static void main(String[] args) throws Exception {\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }", "main", "{\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int ans;", "ans", "if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }", "K<=A", "K", "A", "{\n ans = K;\n }", "ans = K", "ans", "K", "if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }", "K<=A+B", "K", "A+B", "A", "B", "{\n ans = A;\n }", "ans = A", "ans", "A", "{\n ans = A - (K-(A+B));\n }", "ans = A - (K-(A+B))", "ans", "A - (K-(A+B))", "A", "(K-(A+B))", "K", "(A+B)", "A", "B", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n public static void main(String[] args) throws Exception {\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }\n}", "public class Main {\n public static void main(String[] args) throws Exception {\n // Your code here!\n Scanner sc = new Scanner(System.in);\n \n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n \n int K = sc.nextInt();\n \n int ans;\n \n if(K<=A){\n ans = K;\n } else if(K<=A+B){\n ans = A;\n } else {\n ans = A - (K-(A+B));\n }\n \n \n System.out.println(ans);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) throws Exception { // Your code here! Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int ans; if(K<=A){ ans = K; } else if(K<=A+B){ ans = A; } else { ans = A - (K-(A+B)); } System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 17, 41, 13, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 18, 13, 2, 13, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 18, 13, 2, 13, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 18, 13, 2, 13, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 127, 5 ], [ 127, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 8, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 43, 44 ], [ 42, 45 ], [ 42, 46 ], [ 8, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 49, 51 ], [ 8, 52 ], [ 52, 53 ], [ 52, 54 ], [ 54, 55 ], [ 54, 56 ], [ 8, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 59, 62 ], [ 62, 63 ], [ 62, 64 ], [ 59, 65 ], [ 8, 66 ], [ 66, 67 ], [ 66, 68 ], [ 68, 69 ], [ 69, 70 ], [ 68, 71 ], [ 68, 72 ], [ 8, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 75, 77 ], [ 8, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 80, 82 ], [ 8, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 86, 87 ], [ 85, 88 ], [ 88, 89 ], [ 88, 90 ], [ 85, 91 ], [ 8, 92 ], [ 92, 93 ], [ 92, 94 ], [ 94, 95 ], [ 95, 96 ], [ 94, 97 ], [ 94, 98 ], [ 8, 99 ], [ 99, 100 ], [ 99, 101 ], [ 101, 102 ], [ 101, 103 ], [ 8, 104 ], [ 104, 105 ], [ 104, 106 ], [ 106, 107 ], [ 106, 108 ], [ 8, 109 ], [ 109, 110 ], [ 109, 111 ], [ 111, 112 ], [ 112, 113 ], [ 111, 114 ], [ 114, 115 ], [ 114, 116 ], [ 111, 117 ], [ 8, 118 ], [ 118, 119 ], [ 119, 120 ], [ 120, 121 ], [ 120, 122 ], [ 118, 123 ], [ 6, 124 ], [ 124, 125 ], [ 0, 126 ], [ 126, 127 ], [ 126, 128 ] ]
[ "import java.util.*;\npublic class Main {\n public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }", "main", "{\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }", "Scanner input = new Scanner(System.in);", "input", "new Scanner(System.in)", "int a = input.nextInt();", "a", "input.nextInt()", "input.nextInt", "input", "int b = input.nextInt();", "b", "input.nextInt()", "input.nextInt", "input", "int c = input.nextInt();", "c", "input.nextInt()", "input.nextInt", "input", "int k = input.nextInt();", "k", "input.nextInt()", "input.nextInt", "input", "int ans = 0;", "ans", "0", "int count = 0;", "count", "0", "int tmp;", "tmp", "tmp = Math.min(a,k)", "tmp", "Math.min(a,k)", "Math.min", "Math", "a", "k", "count += tmp * 1", "count", "tmp * 1", "tmp", "1", "ans += tmp * 1", "ans", "tmp * 1", "tmp", "1", "k = Math.max(k-tmp,0)", "k", "Math.max(k-tmp,0)", "Math.max", "Math", "k-tmp", "k", "tmp", "0", "tmp = Math.min(b,k)", "tmp", "Math.min(b,k)", "Math.min", "Math", "b", "k", "count += tmp * 1", "count", "tmp * 1", "tmp", "1", "ans += tmp * 0", "ans", "tmp * 0", "tmp", "0", "k = Math.max(k-tmp,0)", "k", "Math.max(k-tmp,0)", "Math.max", "Math", "k-tmp", "k", "tmp", "0", "tmp = Math.min(c,k)", "tmp", "Math.min(c,k)", "Math.min", "Math", "c", "k", "count += tmp * 1", "count", "tmp * 1", "tmp", "1", "ans -= tmp * 1", "ans", "tmp * 1", "tmp", "1", "k = Math.max(k-tmp,0)", "k", "Math.max(k-tmp,0)", "Math.max", "Math", "k-tmp", "k", "tmp", "0", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n int a = input.nextInt();\n int b = input.nextInt();\n int c = input.nextInt();\n int k = input.nextInt();\n int ans = 0;\n int count = 0;\n int tmp;\n tmp = Math.min(a,k);\n count += tmp * 1;\n ans += tmp * 1;\n k = Math.max(k-tmp,0);\n tmp = Math.min(b,k);\n count += tmp * 1;\n ans += tmp * 0;\n k = Math.max(k-tmp,0);\n tmp = Math.min(c,k);\n count += tmp * 1;\n ans -= tmp * 1;\n k = Math.max(k-tmp,0);\n System.out.println(ans);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner input = new Scanner(System.in); int a = input.nextInt(); int b = input.nextInt(); int c = input.nextInt(); int k = input.nextInt(); int ans = 0; int count = 0; int tmp; tmp = Math.min(a,k); count += tmp * 1; ans += tmp * 1; k = Math.max(k-tmp,0); tmp = Math.min(b,k); count += tmp * 1; ans += tmp * 0; k = Math.max(k-tmp,0); tmp = Math.min(c,k); count += tmp * 1; ans -= tmp * 1; k = Math.max(k-tmp,0); System.out.println(ans); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 4, 18, 13, 13, 30, 41, 13, 17, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 0, 13, 13, 0, 13, 40, 13, 4, 18, 13, 13, 4, 18, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 0, 13, 17, 23, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 41, 13, 4, 13, 29, 4, 18, 13, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 142, 8 ], [ 142, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 11, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 11, 23 ], [ 23, 24 ], [ 23, 25 ], [ 25, 26 ], [ 26, 27 ], [ 11, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 11, 33 ], [ 33, 34 ], [ 33, 35 ], [ 35, 36 ], [ 36, 37 ], [ 11, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 42, 43 ], [ 43, 44 ], [ 42, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 50, 52 ], [ 46, 53 ], [ 53, 54 ], [ 53, 55 ], [ 46, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 64, 65 ], [ 64, 66 ], [ 56, 67 ], [ 67, 68 ], [ 67, 69 ], [ 46, 70 ], [ 70, 71 ], [ 70, 72 ], [ 72, 73 ], [ 46, 74 ], [ 74, 75 ], [ 75, 76 ], [ 74, 77 ], [ 11, 78 ], [ 78, 79 ], [ 79, 80 ], [ 9, 81 ], [ 81, 82 ], [ 142, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 83, 87 ], [ 87, 88 ], [ 83, 89 ], [ 89, 90 ], [ 89, 91 ], [ 91, 92 ], [ 92, 93 ], [ 92, 94 ], [ 91, 95 ], [ 95, 96 ], [ 95, 97 ], [ 89, 98 ], [ 98, 99 ], [ 83, 100 ], [ 100, 101 ], [ 100, 102 ], [ 102, 103 ], [ 103, 104 ], [ 104, 105 ], [ 105, 106 ], [ 105, 107 ], [ 104, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 103, 112 ], [ 112, 113 ], [ 113, 114 ], [ 113, 115 ], [ 102, 116 ], [ 116, 117 ], [ 117, 118 ], [ 118, 119 ], [ 83, 120 ], [ 120, 121 ], [ 120, 122 ], [ 122, 123 ], [ 123, 124 ], [ 123, 125 ], [ 125, 126 ], [ 122, 127 ], [ 127, 128 ], [ 128, 129 ], [ 129, 130 ], [ 128, 131 ], [ 83, 132 ], [ 132, 133 ], [ 132, 134 ], [ 134, 135 ], [ 135, 136 ], [ 136, 137 ], [ 137, 138 ], [ 136, 139 ], [ 139, 140 ], [ 0, 141 ], [ 141, 142 ], [ 141, 143 ] ]
[ "import java.io.*;\nimport java.util.StringTokenizer;\n\npublic class Main {\n public static void main(String[] args) throws IOException {\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }\n static class InputReader{\n private BufferedReader in;\n private StringTokenizer tokenizer;\n public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }\n public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }\n public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }\n public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }\n }\n}", "import java.io.*;", "io.*", "java", "import java.util.StringTokenizer;", "StringTokenizer", "java.util", "public class Main {\n public static void main(String[] args) throws IOException {\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }\n static class InputReader{\n private BufferedReader in;\n private StringTokenizer tokenizer;\n public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }\n public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }\n public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }\n public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }\n }\n}", "Main", "public static void main(String[] args) throws IOException {\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }", "main", "{\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }", "PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));", "out", "new PrintWriter(new OutputStreamWriter(System.out))", "InputReader in=new InputReader(System.in);", "in", "new InputReader(System.in)", "int a=in.nextInt();", "a", "in.nextInt()", "in.nextInt", "in", "int b=in.nextInt();", "b", "in.nextInt()", "in.nextInt", "in", "int c=in.nextInt();", "c", "in.nextInt()", "in.nextInt", "in", "int k=in.nextInt();", "k", "in.nextInt()", "in.nextInt", "in", "if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }", "a>k", "a", "k", "out.println(k)", "out.println", "out", "k", "{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }", "int res=0;", "res", "0", "res+=a", "res", "a", "k-=a", "k", "a", "if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;", "b>k", "b", "k", "{\n res += k;\n k=0;\n }", "res += k", "res", "k", "k=0", "k", "0", "k-=b", "k", "b", "res+=-k", "res", "-k", "k", "out.println(res)", "out.println", "out", "res", "out.flush()", "out.flush", "out", "String[] args", "args", "static class InputReader{\n private BufferedReader in;\n private StringTokenizer tokenizer;\n public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }\n public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }\n public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }\n public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }\n }", "InputReader", "private BufferedReader in;", "in", "private StringTokenizer tokenizer;", "tokenizer", "public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }", "InputReader", "{\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }", "in = new BufferedReader(new InputStreamReader(stream),32768)", "in", "new BufferedReader(new InputStreamReader(stream),32768)", "tokenizer = null", "tokenizer", "null", "InputStream stream", "stream", "public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }", "next", "{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }", "while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }", "tokenizer==null || !tokenizer.hasMoreTokens()", "tokenizer==null", "tokenizer", "null", "!tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens", "tokenizer", "{\n tokenizer = new StringTokenizer(in.readLine());\n }", "tokenizer = new StringTokenizer(in.readLine())", "tokenizer", "new StringTokenizer(in.readLine())", "return tokenizer.nextToken();", "tokenizer.nextToken()", "tokenizer.nextToken", "tokenizer", "public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }", "nextLong", "{\n String next = next();\n return Long.valueOf(next);\n }", "String next = next();", "next", "next()", "next", "return Long.valueOf(next);", "Long.valueOf(next)", "Long.valueOf", "Long", "next", "public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }", "nextInt", "{\n return Integer.valueOf(next());\n }", "return Integer.valueOf(next());", "Integer.valueOf(next())", "Integer.valueOf", "Integer", "next()", "next", "public class Main {\n public static void main(String[] args) throws IOException {\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }\n static class InputReader{\n private BufferedReader in;\n private StringTokenizer tokenizer;\n public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }\n public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }\n public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }\n public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }\n }\n}", "public class Main {\n public static void main(String[] args) throws IOException {\n PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));\n InputReader in=new InputReader(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n if(a>k)\n out.println(k);\n else{\n int res=0;\n res+=a;\n k-=a;\n if(b>k) {\n res += k;\n k=0;\n }\n else\n k-=b;\n res+=-k;\n out.println(res);\n }\n out.flush();\n }\n static class InputReader{\n private BufferedReader in;\n private StringTokenizer tokenizer;\n public InputReader(InputStream stream){\n in = new BufferedReader(new InputStreamReader(stream),32768);\n tokenizer = null;\n }\n public String next() throws IOException{\n while(tokenizer==null || !tokenizer.hasMoreTokens()){\n tokenizer = new StringTokenizer(in.readLine());\n }\n return tokenizer.nextToken();\n }\n public Long nextLong() throws IOException {\n String next = next();\n return Long.valueOf(next);\n }\n public int nextInt() throws IOException{\n return Integer.valueOf(next());\n }\n }\n}", "Main" ]
import java.io.*; import java.util.StringTokenizer; public class Main { public static void main(String[] args) throws IOException { PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out)); InputReader in=new InputReader(System.in); int a=in.nextInt(); int b=in.nextInt(); int c=in.nextInt(); int k=in.nextInt(); if(a>k) out.println(k); else{ int res=0; res+=a; k-=a; if(b>k) { res += k; k=0; } else k-=b; res+=-k; out.println(res); } out.flush(); } static class InputReader{ private BufferedReader in; private StringTokenizer tokenizer; public InputReader(InputStream stream){ in = new BufferedReader(new InputStreamReader(stream),32768); tokenizer = null; } public String next() throws IOException{ while(tokenizer==null || !tokenizer.hasMoreTokens()){ tokenizer = new StringTokenizer(in.readLine()); } return tokenizer.nextToken(); } public Long nextLong() throws IOException { String next = next(); return Long.valueOf(next); } public int nextInt() throws IOException{ return Integer.valueOf(next()); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 8, 2, 13, 13, 13, 8, 2, 13, 2, 13, 13, 4, 18, 13, 13, 13, 2, 13, 4, 18, 13, 2, 2, 13, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 70, 5 ], [ 70, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 35, 36 ], [ 35, 37 ], [ 34, 38 ], [ 34, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 42, 44 ], [ 39, 45 ], [ 45, 46 ], [ 46, 47 ], [ 45, 48 ], [ 45, 49 ], [ 39, 50 ], [ 50, 51 ], [ 50, 52 ], [ 52, 53 ], [ 53, 54 ], [ 52, 55 ], [ 56, 56 ], [ 56, 57 ], [ 56, 58 ], [ 56, 59 ], [ 52, 60 ], [ 8, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 6, 67 ], [ 67, 68 ], [ 0, 69 ], [ 69, 70 ], [ 69, 71 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c);", "ans", "k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c)", "k <= a", "k", "a", "k", "k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c)", "k <= a + b", "k", "a + b", "a", "b", "Math.min(k, a)", "Math.min", "Math", "k", "a", "a - Math.min(k - a - b, c)", "a", "Math.min(k - a - b, c)", "Math.min", "Math", "k - a - b", "k - a - b", "k", "a", "b", "c", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\t\n\t\tint ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); \n\t\t\n\t\tSystem.out.println(ans);\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int ans = k <= a ? k : k <= a + b ? Math.min(k, a) : a - Math.min(k - a - b, c); System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 2, 13, 13, 13, 30, 14, 2, 13, 13, 4, 18, 18, 13, 13, 13, 4, 18, 18, 13, 13, 13, 14, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 2, 13, 13, 13, 40, 17, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 80, 5 ], [ 80, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 34, 35 ], [ 34, 36 ], [ 33, 37 ], [ 32, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 43, 48 ], [ 39, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 49, 54 ], [ 32, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 55, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 67, 68 ], [ 67, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 69, 75 ], [ 75, 76 ], [ 6, 77 ], [ 77, 78 ], [ 0, 79 ], [ 79, 80 ], [ 79, 81 ] ]
[ "import java.util.*;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}", "(A + B) >= K", "(A + B)", "A", "B", "K", "{\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}", "if (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);", "A > K", "A", "K", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}", "(A + B) < K", "(A + B)", "A", "B", "K", "{\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}", "System.out.println(A + (K - A -B) * - 1)", "System.out.println", "System.out", "System", "System.out", "A + (K - A -B) * - 1", "A", "(K - A -B) * - 1", "(K - A -B)", "K - A -B", "K", "A", "B", "- 1", "1", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n if((A + B) >= K ) {\n\t\t\tif (A > K)\n\t\tSystem.out.println(K);\n\t\t\telse\n\t\tSystem.out.println(A);\n\t\t}\n\t\telse if((A + B) < K ) {\n\t\tSystem.out.println(A + (K - A -B) * - 1);\n\t\t}\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); if((A + B) >= K ) { if (A > K) System.out.println(K); else System.out.println(A); } else if((A + B) < K ) { System.out.println(A + (K - A -B) * - 1); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 2, 13, 13, 13, 30, 0, 13, 2, 2, 2, 17, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 83, 5 ], [ 83, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 49, 51 ], [ 46, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 46, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 60, 60 ], [ 60, 61 ], [ 60, 62 ], [ 60, 63 ], [ 56, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 67, 73 ], [ 8, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 74, 79 ], [ 6, 80 ], [ 80, 81 ], [ 0, 82 ], [ 82, 83 ], [ 82, 84 ] ]
[ "\nimport java.util.*;\n\npublic class Main {\n public static void main(final String[] args) {\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(final String[] args) {\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }\n}", "Main", "public static void main(final String[] args) {\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }", "main", "{\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }", "final Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "final int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "final int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "final int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "final int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "sc.close()", "sc.close", "sc", "int result = 0;", "result", "0", "if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }", "a >= k", "a", "k", "{\n result = k;\n }", "result = k", "result", "k", "if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }", "b >= k - a", "b", "k - a", "k", "a", "{\n result = a;\n }", "result = a", "result", "a", "if (c >= k - b - a) {\n result = 2 * a + b - k;\n }", "c >= k - b - a", "c", "k - b - a", "k - b - a", "k", "b", "a", "{\n result = 2 * a + b - k;\n }", "result = 2 * a + b - k", "result", "2 * a + b - k", "2 * a + b", "2 * a", "2", "a", "b", "k", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "final String[] args", "args", "public class Main {\n public static void main(final String[] args) {\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }\n}", "public class Main {\n public static void main(final String[] args) {\n final Scanner sc = new Scanner(System.in);\n // 整数の入力\n // final int a = sc.nextInt();\n // 文字列の入力\n // final String s1 = sc.next();\n final int a = sc.nextInt();\n final int b = sc.nextInt();\n final int c = sc.nextInt();\n final int k = sc.nextInt();\n sc.close();\n int result = 0;\n if (a >= k) {\n result = k;\n } else if (b >= k - a) {\n result = a;\n } else if (c >= k - b - a) {\n result = 2 * a + b - k;\n }\n\n System.out.println(result);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(final String[] args) { final Scanner sc = new Scanner(System.in); // 整数の入力 // final int a = sc.nextInt(); // 文字列の入力 // final String s1 = sc.next(); final int a = sc.nextInt(); final int b = sc.nextInt(); final int c = sc.nextInt(); final int k = sc.nextInt(); sc.close(); int result = 0; if (a >= k) { result = k; } else if (b >= k - a) { result = a; } else if (c >= k - b - a) { result = 2 * a + b - k; } System.out.println(result); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 17, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 77, 5 ], [ 77, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 43, 45 ], [ 35, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 50, 52 ], [ 8, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 53, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 8, 65 ], [ 65, 66 ], [ 65, 67 ], [ 8, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 6, 74 ], [ 74, 75 ], [ 0, 76 ], [ 76, 77 ], [ 76, 78 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }\n}", "Main", "public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }", "main", "{\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }", "final Scanner scanner = new Scanner(System.in);", "scanner", "new Scanner(System.in)", "final int a = scanner.nextInt();", "a", "scanner.nextInt()", "scanner.nextInt", "scanner", "final int b = scanner.nextInt();", "b", "scanner.nextInt()", "scanner.nextInt", "scanner", "final int c = scanner.nextInt();", "c", "scanner.nextInt()", "scanner.nextInt", "scanner", "int k = scanner.nextInt();", "k", "scanner.nextInt()", "scanner.nextInt", "scanner", "int sum = 0;", "sum", "0", "if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }", "k >= a", "k", "a", "{\n k -= a;\n sum += a;\n }", "k -= a", "k", "a", "sum += a", "sum", "a", "{\n sum += k;\n k = 0;\n }", "sum += k", "sum", "k", "k = 0", "k", "0", "if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }", "k >= b", "k", "b", "{\n k -= b;\n }", "k -= b", "k", "b", "{\n k = 0;\n }", "k = 0", "k", "0", "sum -= k", "sum", "k", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n final Scanner scanner = new Scanner(System.in);\n\n final int a = scanner.nextInt();\n final int b = scanner.nextInt();\n final int c = scanner.nextInt();\n int k = scanner.nextInt();\n\n int sum = 0;\n if (k >= a) {\n k -= a;\n sum += a;\n } else {\n sum += k;\n k = 0;\n }\n\n if (k >= b) {\n k -= b;\n } else {\n k = 0;\n }\n\n sum -= k;\n\n System.out.println(sum);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { final Scanner scanner = new Scanner(System.in); final int a = scanner.nextInt(); final int b = scanner.nextInt(); final int c = scanner.nextInt(); int k = scanner.nextInt(); int sum = 0; if (k >= a) { k -= a; sum += a; } else { sum += k; k = 0; } if (k >= b) { k -= b; } else { k = 0; } sum -= k; System.out.println(sum); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 4, 18, 13, 8, 2, 2, 13, 13, 13, 2, 2, 2, 17, 13, 13, 13, 4, 18, 13, 13, 13, 23, 13, 23, 13, 23, 13, 6, 13, 41, 13, 41, 13, 17, 41, 13, 17, 12, 13, 30, 0, 18, 36, 13, 13, 23, 13, 12, 13, 30, 4, 13, 20, 23, 13, 12, 13, 30, 38, 5, 13, 30, 37, 20, 30, 4, 18, 13, 13, 0, 13, 17, 29, 36, 23, 13, 12, 13, 30, 38, 5, 13, 30, 37, 20, 30, 4, 18, 13, 13, 17, 4, 18, 13, 0, 13, 17, 29, 36, 23, 13, 12, 13, 30, 14, 40, 13, 30, 4, 13, 17, 29, 4, 13, 13, 23, 13, 12, 13, 30, 29, 4, 13, 4, 18, 13, 13, 23, 13, 12, 13, 30, 4, 13, 4, 18, 13, 0, 13, 17, 14, 13, 30, 38, 5, 13, 30, 37, 20, 30, 4, 18, 13, 29, 36, 12, 13, 30, 38, 5, 13, 30, 37, 20, 30, 4, 18, 13, 13, 6, 13, 41, 13, 17, 41, 13, 17, 12, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 14, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 37, 20, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 38, 5, 13, 30, 37, 20, 30, 4, 18, 18, 36, 13, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 22, 23 ], [ 22, 24 ], [ 0, 25 ], [ 25, 26 ], [ 25, 27 ], [ 0, 28 ], [ 28, 29 ], [ 28, 30 ], [ 0, 31 ], [ 31, 32 ], [ 31, 33 ], [ 0, 34 ], [ 34, 35 ], [ 34, 36 ], [ 0, 37 ], [ 37, 38 ], [ 37, 39 ], [ 0, 40 ], [ 40, 41 ], [ 40, 42 ], [ 0, 43 ], [ 343, 44 ], [ 343, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 50, 52 ], [ 47, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 55, 57 ], [ 47, 58 ], [ 58, 59 ], [ 58, 60 ], [ 47, 61 ], [ 61, 62 ], [ 61, 63 ], [ 47, 64 ], [ 64, 65 ], [ 64, 66 ], [ 47, 67 ], [ 67, 68 ], [ 68, 69 ], [ 67, 70 ], [ 67, 71 ], [ 67, 72 ], [ 47, 73 ], [ 73, 74 ], [ 74, 75 ], [ 45, 76 ], [ 76, 77 ], [ 343, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 80, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 86, 87 ], [ 82, 88 ], [ 88, 89 ], [ 88, 90 ], [ 90, 91 ], [ 91, 92 ], [ 82, 93 ], [ 93, 94 ], [ 93, 95 ], [ 95, 96 ], [ 96, 97 ], [ 82, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 101, 102 ], [ 82, 103 ], [ 103, 104 ], [ 104, 105 ], [ 105, 106 ], [ 106, 107 ], [ 105, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 110, 112 ], [ 109, 113 ], [ 108, 114 ], [ 114, 115 ], [ 115, 116 ], [ 116, 117 ], [ 116, 118 ], [ 115, 119 ], [ 114, 120 ], [ 108, 121 ], [ 121, 122 ], [ 122, 123 ], [ 121, 124 ], [ 121, 125 ], [ 80, 126 ], [ 126, 127 ], [ 80, 128 ], [ 128, 129 ], [ 80, 130 ], [ 130, 131 ], [ 343, 132 ], [ 132, 133 ], [ 132, 134 ], [ 134, 135 ], [ 132, 136 ], [ 136, 137 ], [ 136, 138 ], [ 132, 139 ], [ 139, 140 ], [ 139, 141 ], [ 132, 142 ], [ 142, 143 ], [ 142, 144 ], [ 144, 145 ], [ 145, 146 ], [ 146, 147 ], [ 146, 148 ], [ 145, 149 ], [ 142, 150 ], [ 150, 151 ], [ 132, 152 ], [ 152, 153 ], [ 152, 154 ], [ 154, 155 ], [ 155, 156 ], [ 155, 157 ], [ 152, 158 ], [ 158, 159 ], [ 132, 160 ], [ 160, 161 ], [ 160, 162 ], [ 162, 163 ], [ 163, 164 ], [ 164, 165 ], [ 164, 166 ], [ 166, 167 ], [ 167, 168 ], [ 163, 169 ], [ 169, 170 ], [ 170, 171 ], [ 171, 172 ], [ 170, 173 ], [ 169, 174 ], [ 174, 175 ], [ 174, 176 ], [ 162, 177 ], [ 177, 178 ], [ 160, 179 ], [ 179, 180 ], [ 132, 181 ], [ 181, 182 ], [ 181, 183 ], [ 183, 184 ], [ 184, 185 ], [ 185, 186 ], [ 185, 187 ], [ 187, 188 ], [ 188, 189 ], [ 184, 190 ], [ 190, 191 ], [ 191, 192 ], [ 192, 193 ], [ 191, 194 ], [ 191, 195 ], [ 191, 196 ], [ 196, 197 ], [ 197, 198 ], [ 190, 199 ], [ 199, 200 ], [ 199, 201 ], [ 183, 202 ], [ 202, 203 ], [ 181, 204 ], [ 204, 205 ], [ 132, 206 ], [ 206, 207 ], [ 206, 208 ], [ 208, 209 ], [ 209, 210 ], [ 210, 211 ], [ 209, 212 ], [ 212, 213 ], [ 213, 214 ], [ 213, 215 ], [ 208, 216 ], [ 216, 217 ], [ 217, 218 ], [ 217, 219 ], [ 206, 220 ], [ 220, 221 ], [ 132, 222 ], [ 222, 223 ], [ 222, 224 ], [ 224, 225 ], [ 225, 226 ], [ 226, 227 ], [ 226, 228 ], [ 228, 229 ], [ 229, 230 ], [ 228, 231 ], [ 222, 232 ], [ 232, 233 ], [ 132, 234 ], [ 234, 235 ], [ 234, 236 ], [ 236, 237 ], [ 237, 238 ], [ 237, 239 ], [ 239, 240 ], [ 240, 241 ], [ 236, 242 ], [ 242, 243 ], [ 242, 244 ], [ 236, 245 ], [ 245, 246 ], [ 245, 247 ], [ 247, 248 ], [ 248, 249 ], [ 249, 250 ], [ 249, 251 ], [ 251, 252 ], [ 252, 253 ], [ 248, 254 ], [ 254, 255 ], [ 255, 256 ], [ 256, 257 ], [ 236, 258 ], [ 258, 259 ], [ 132, 260 ], [ 260, 261 ], [ 260, 262 ], [ 262, 263 ], [ 263, 264 ], [ 264, 265 ], [ 264, 266 ], [ 266, 267 ], [ 267, 268 ], [ 263, 269 ], [ 269, 270 ], [ 270, 271 ], [ 271, 272 ], [ 132, 273 ], [ 343, 274 ], [ 274, 275 ], [ 274, 276 ], [ 276, 277 ], [ 276, 278 ], [ 274, 279 ], [ 279, 280 ], [ 279, 281 ], [ 274, 282 ], [ 282, 283 ], [ 282, 284 ], [ 284, 285 ], [ 285, 286 ], [ 285, 287 ], [ 282, 288 ], [ 288, 289 ], [ 274, 290 ], [ 290, 291 ], [ 290, 292 ], [ 292, 293 ], [ 293, 294 ], [ 294, 295 ], [ 295, 296 ], [ 295, 297 ], [ 294, 298 ], [ 298, 299 ], [ 299, 300 ], [ 300, 301 ], [ 293, 302 ], [ 302, 303 ], [ 303, 304 ], [ 304, 305 ], [ 304, 306 ], [ 306, 307 ], [ 307, 308 ], [ 303, 309 ], [ 309, 310 ], [ 310, 311 ], [ 310, 312 ], [ 292, 313 ], [ 313, 314 ], [ 314, 315 ], [ 315, 316 ], [ 274, 317 ], [ 317, 318 ], [ 317, 319 ], [ 319, 320 ], [ 320, 321 ], [ 321, 322 ], [ 322, 323 ], [ 321, 324 ], [ 324, 325 ], [ 274, 326 ], [ 326, 327 ], [ 326, 328 ], [ 328, 329 ], [ 329, 330 ], [ 330, 331 ], [ 330, 332 ], [ 332, 333 ], [ 333, 334 ], [ 329, 335 ], [ 335, 336 ], [ 336, 337 ], [ 337, 338 ], [ 338, 339 ], [ 338, 340 ], [ 274, 341 ], [ 0, 342 ], [ 342, 343 ], [ 342, 344 ] ]
[ "import java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.io.BufferedOutputStream;\nimport java.io.UncheckedIOException;\nimport java.nio.charset.Charset;\nimport java.util.StringTokenizer;\nimport java.io.Writer;\nimport java.io.OutputStreamWriter;\nimport java.io.BufferedReader;\nimport java.io.InputStream;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n *\n * @author mikit\n */\npublic class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }\n\n }\n\n static class LightWriter implements AutoCloseable {\n private final Writer out;\n private boolean autoflush = false;\n private boolean breaked = true;\n\n public LightWriter(Writer out) {\n this.out = out;\n }\n\n public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }\n\n public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }\n\n public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }\n\n public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }\n\n public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n\n static class LightScanner implements AutoCloseable {\n private BufferedReader reader = null;\n private StringTokenizer tokenizer = null;\n\n public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }\n\n public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }\n\n public int ints() {\n return Integer.parseInt(string());\n }\n\n public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n}\n", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.io.BufferedOutputStream;", "BufferedOutputStream", "java.io", "import java.io.UncheckedIOException;", "UncheckedIOException", "java.io", "import java.nio.charset.Charset;", "Charset", "java.nio.charset", "import java.util.StringTokenizer;", "StringTokenizer", "java.util", "import java.io.Writer;", "Writer", "java.io", "import java.io.OutputStreamWriter;", "OutputStreamWriter", "java.io", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }\n\n }\n\n static class LightWriter implements AutoCloseable {\n private final Writer out;\n private boolean autoflush = false;\n private boolean breaked = true;\n\n public LightWriter(Writer out) {\n this.out = out;\n }\n\n public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }\n\n public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }\n\n public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }\n\n public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }\n\n public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n\n static class LightScanner implements AutoCloseable {\n private BufferedReader reader = null;\n private StringTokenizer tokenizer = null;\n\n public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }\n\n public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }\n\n public int ints() {\n return Integer.parseInt(string());\n }\n\n public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n}", "Main", "public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "LightScanner in = new LightScanner(inputStream);", "in", "new LightScanner(inputStream)", "LightWriter out = new LightWriter(outputStream);", "out", "new LightWriter(outputStream)", "BEasyLinearProgramming solver = new BEasyLinearProgramming();", "solver", "new BEasyLinearProgramming()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class BEasyLinearProgramming {\n public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }\n\n }", "BEasyLinearProgramming", "public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }", "solve", "{\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }", "int a = in.ints()", "a", "in.ints()", "in.ints", "in", "b = in.ints()", "b", "in.ints()", "in.ints", "in", "c = in.ints()", "c", "in.ints()", "in.ints", "in", "k = in.ints();", "k", "in.ints()", "in.ints", "in", "out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln()", "out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln", "out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k))", "out.ans", "out", "a + b < k ? 2 * a + b - k : Math.min(a, k)", "a + b < k", "a + b", "a", "b", "k", "2 * a + b - k", "2 * a + b", "2 * a", "2", "a", "b", "k", "Math.min(a, k)", "Math.min", "Math", "a", "k", "int testNumber", "testNumber", "LightScanner in", "in", "LightWriter out", "out", "static class LightWriter implements AutoCloseable {\n private final Writer out;\n private boolean autoflush = false;\n private boolean breaked = true;\n\n public LightWriter(Writer out) {\n this.out = out;\n }\n\n public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }\n\n public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }\n\n public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }\n\n public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }\n\n public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }", "LightWriter", "private final Writer out;", "out", "private boolean autoflush = false;", "autoflush", "false", "private boolean breaked = true;", "breaked", "true", "public LightWriter(Writer out) {\n this.out = out;\n }", "LightWriter", "{\n this.out = out;\n }", "this.out = out", "this.out", "this", "this.out", "out", "Writer out", "out", "public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }", "LightWriter", "{\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }", "this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()))", "this", "new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset())", "OutputStream out", "out", "public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }", "print", "{\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }", "try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "IOException ex", "{\n throw new UncheckedIOException(ex);\n }", "throw new UncheckedIOException(ex);", "new UncheckedIOException(ex)", "{\n out.write(c);\n breaked = false;\n }", "out.write(c)", "out.write", "out", "c", "breaked = false", "breaked", "false", "return this;", "this", "char c", "c", "public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }", "print", "{\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }", "try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "IOException ex", "{\n throw new UncheckedIOException(ex);\n }", "throw new UncheckedIOException(ex);", "new UncheckedIOException(ex)", "{\n out.write(s, 0, s.length());\n breaked = false;\n }", "out.write(s, 0, s.length())", "out.write", "out", "s", "0", "s.length()", "s.length", "s", "breaked = false", "breaked", "false", "return this;", "this", "String s", "s", "public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }", "ans", "{\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }", "if (!breaked) {\n print(' ');\n }", "!breaked", "breaked", "{\n print(' ');\n }", "print(' ')", "print", "' '", "return print(s);", "print(s)", "print", "s", "String s", "s", "public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }", "ans", "{\n return ans(Integer.toString(i));\n }", "return ans(Integer.toString(i));", "ans(Integer.toString(i))", "ans", "Integer.toString(i)", "Integer.toString", "Integer", "i", "int i", "i", "public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }", "ln", "{\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }", "print(System.lineSeparator())", "print", "System.lineSeparator()", "System.lineSeparator", "System", "breaked = true", "breaked", "true", "if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "autoflush", "{\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "IOException ex", "{\n throw new UncheckedIOException(ex);\n }", "throw new UncheckedIOException(ex);", "new UncheckedIOException(ex)", "{\n out.flush();\n }", "out.flush()", "out.flush", "out", "return this;", "this", "public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "close", "{\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "IOException ex", "{\n throw new UncheckedIOException(ex);\n }", "throw new UncheckedIOException(ex);", "new UncheckedIOException(ex)", "{\n out.close();\n }", "out.close()", "out.close", "out", "AutoCloseable", "static class LightScanner implements AutoCloseable {\n private BufferedReader reader = null;\n private StringTokenizer tokenizer = null;\n\n public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }\n\n public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }\n\n public int ints() {\n return Integer.parseInt(string());\n }\n\n public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }", "LightScanner", "private BufferedReader reader = null;", "reader", "null", "private StringTokenizer tokenizer = null;", "tokenizer", "null", "public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }", "LightScanner", "{\n reader = new BufferedReader(new InputStreamReader(in));\n }", "reader = new BufferedReader(new InputStreamReader(in))", "reader", "new BufferedReader(new InputStreamReader(in))", "InputStream in", "in", "public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }", "string", "{\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }", "if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }", "tokenizer == null || !tokenizer.hasMoreTokens()", "tokenizer == null", "tokenizer", "null", "!tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens", "tokenizer", "{\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }", "try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }", "catch (IOException e) {\n throw new UncheckedIOException(e);\n }", "IOException e", "{\n throw new UncheckedIOException(e);\n }", "throw new UncheckedIOException(e);", "new UncheckedIOException(e)", "{\n tokenizer = new StringTokenizer(reader.readLine());\n }", "tokenizer = new StringTokenizer(reader.readLine())", "tokenizer", "new StringTokenizer(reader.readLine())", "return tokenizer.nextToken();", "tokenizer.nextToken()", "tokenizer.nextToken", "tokenizer", "public int ints() {\n return Integer.parseInt(string());\n }", "ints", "{\n return Integer.parseInt(string());\n }", "return Integer.parseInt(string());", "Integer.parseInt(string())", "Integer.parseInt", "Integer", "string()", "string", "public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "close", "{\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }", "try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }", "IOException ex", "{\n throw new UncheckedIOException(ex);\n }", "throw new UncheckedIOException(ex);", "new UncheckedIOException(ex)", "{\n this.reader.close();\n }", "this.reader.close()", "this.reader.close", "this.reader", "this", "this.reader", "AutoCloseable", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }\n\n }\n\n static class LightWriter implements AutoCloseable {\n private final Writer out;\n private boolean autoflush = false;\n private boolean breaked = true;\n\n public LightWriter(Writer out) {\n this.out = out;\n }\n\n public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }\n\n public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }\n\n public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }\n\n public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }\n\n public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n\n static class LightScanner implements AutoCloseable {\n private BufferedReader reader = null;\n private StringTokenizer tokenizer = null;\n\n public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }\n\n public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }\n\n public int ints() {\n return Integer.parseInt(string());\n }\n\n public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n}", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n LightScanner in = new LightScanner(inputStream);\n LightWriter out = new LightWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, LightScanner in, LightWriter out) {\n int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints();\n out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln();\n }\n\n }\n\n static class LightWriter implements AutoCloseable {\n private final Writer out;\n private boolean autoflush = false;\n private boolean breaked = true;\n\n public LightWriter(Writer out) {\n this.out = out;\n }\n\n public LightWriter(OutputStream out) {\n this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset()));\n }\n\n public LightWriter print(char c) {\n try {\n out.write(c);\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter print(String s) {\n try {\n out.write(s, 0, s.length());\n breaked = false;\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n return this;\n }\n\n public LightWriter ans(String s) {\n if (!breaked) {\n print(' ');\n }\n return print(s);\n }\n\n public LightWriter ans(int i) {\n return ans(Integer.toString(i));\n }\n\n public LightWriter ln() {\n print(System.lineSeparator());\n breaked = true;\n if (autoflush) {\n try {\n out.flush();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n return this;\n }\n\n public void close() {\n try {\n out.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n\n static class LightScanner implements AutoCloseable {\n private BufferedReader reader = null;\n private StringTokenizer tokenizer = null;\n\n public LightScanner(InputStream in) {\n reader = new BufferedReader(new InputStreamReader(in));\n }\n\n public String string() {\n if (tokenizer == null || !tokenizer.hasMoreTokens()) {\n try {\n tokenizer = new StringTokenizer(reader.readLine());\n } catch (IOException e) {\n throw new UncheckedIOException(e);\n }\n }\n return tokenizer.nextToken();\n }\n\n public int ints() {\n return Integer.parseInt(string());\n }\n\n public void close() {\n try {\n this.reader.close();\n } catch (IOException ex) {\n throw new UncheckedIOException(ex);\n }\n }\n\n }\n}", "Main" ]
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.io.IOException; import java.io.InputStreamReader; import java.io.BufferedOutputStream; import java.io.UncheckedIOException; import java.nio.charset.Charset; import java.util.StringTokenizer; import java.io.Writer; import java.io.OutputStreamWriter; import java.io.BufferedReader; import java.io.InputStream; /** * Built using CHelper plug-in * Actual solution is at the top * * @author mikit */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; LightScanner in = new LightScanner(inputStream); LightWriter out = new LightWriter(outputStream); BEasyLinearProgramming solver = new BEasyLinearProgramming(); solver.solve(1, in, out); out.close(); } static class BEasyLinearProgramming { public void solve(int testNumber, LightScanner in, LightWriter out) { int a = in.ints(), b = in.ints(), c = in.ints(), k = in.ints(); out.ans(a + b < k ? 2 * a + b - k : Math.min(a, k)).ln(); } } static class LightWriter implements AutoCloseable { private final Writer out; private boolean autoflush = false; private boolean breaked = true; public LightWriter(Writer out) { this.out = out; } public LightWriter(OutputStream out) { this(new OutputStreamWriter(new BufferedOutputStream(out), Charset.defaultCharset())); } public LightWriter print(char c) { try { out.write(c); breaked = false; } catch (IOException ex) { throw new UncheckedIOException(ex); } return this; } public LightWriter print(String s) { try { out.write(s, 0, s.length()); breaked = false; } catch (IOException ex) { throw new UncheckedIOException(ex); } return this; } public LightWriter ans(String s) { if (!breaked) { print(' '); } return print(s); } public LightWriter ans(int i) { return ans(Integer.toString(i)); } public LightWriter ln() { print(System.lineSeparator()); breaked = true; if (autoflush) { try { out.flush(); } catch (IOException ex) { throw new UncheckedIOException(ex); } } return this; } public void close() { try { out.close(); } catch (IOException ex) { throw new UncheckedIOException(ex); } } } static class LightScanner implements AutoCloseable { private BufferedReader reader = null; private StringTokenizer tokenizer = null; public LightScanner(InputStream in) { reader = new BufferedReader(new InputStreamReader(in)); } public String string() { if (tokenizer == null || !tokenizer.hasMoreTokens()) { try { tokenizer = new StringTokenizer(reader.readLine()); } catch (IOException e) { throw new UncheckedIOException(e); } } return tokenizer.nextToken(); } public int ints() { return Integer.parseInt(string()); } public void close() { try { this.reader.close(); } catch (IOException ex) { throw new UncheckedIOException(ex); } } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 17, 14, 2, 2, 13, 13, 13, 30, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 41, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 102, 5 ], [ 102, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 52, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 52, 57 ], [ 47, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 59, 63 ], [ 58, 64 ], [ 64, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 65, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 70, 75 ], [ 65, 76 ], [ 76, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 58, 83 ], [ 83, 84 ], [ 84, 85 ], [ 84, 86 ], [ 87, 87 ], [ 87, 88 ], [ 87, 89 ], [ 87, 90 ], [ 83, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 91, 96 ], [ 96, 97 ], [ 96, 98 ], [ 6, 99 ], [ 99, 100 ], [ 0, 101 ], [ 101, 102 ], [ 101, 103 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int one = Integer.parseInt(sc.next());", "one", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int zero = Integer.parseInt(sc.next());", "zero", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int min = Integer.parseInt(sc.next());", "min", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int count = Integer.parseInt(sc.next());", "count", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int time = 0;", "time", "0", "if(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}", "count==0", "count", "0", "{\n\t\t\tSystem.out.println(0);\n\t\t}", "System.out.println(0)", "System.out.println", "System.out", "System", "System.out", "0", "if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}", "one+zero>=count", "one+zero", "one", "zero", "count", "{\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}", "if(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}", "one>=count", "one", "count", "{\n\t\t\tSystem.out.println(count);}", "System.out.println(count)", "System.out.println", "System.out", "System", "System.out", "count", "{\n\t\t\t\tSystem.out.println(one);\n\t\t\t}", "System.out.println(one)", "System.out.println", "System.out", "System", "System.out", "one", "{\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}", "int mins = count -one-zero;", "mins", "count -one-zero", "count -one-zero", "count", "one", "zero", "System.out.println(one-mins)", "System.out.println", "System.out", "System", "System.out", "one-mins", "one", "mins", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint one = Integer.parseInt(sc.next());\n\t\tint zero = Integer.parseInt(sc.next());\n\t\tint min = Integer.parseInt(sc.next());\n\t\tint count = Integer.parseInt(sc.next());\n\t\tint time = 0;\n\t\tif(count==0) {\n\t\t\tSystem.out.println(0);\n\t\t}\n\t\telse if(one+zero>=count) {\n\t\t\tif(one>=count) {\n\t\t\tSystem.out.println(count);}else {\n\t\t\t\tSystem.out.println(one);\n\t\t\t}\n\t\t}else {\n\t\t\tint mins = count -one-zero;\n\t\t\tSystem.out.println(one-mins);\n\t\t}\n}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int one = Integer.parseInt(sc.next()); int zero = Integer.parseInt(sc.next()); int min = Integer.parseInt(sc.next()); int count = Integer.parseInt(sc.next()); int time = 0; if(count==0) { System.out.println(0); } else if(one+zero>=count) { if(one>=count) { System.out.println(count);}else { System.out.println(one); } }else { int mins = count -one-zero; System.out.println(one-mins); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 2, 2, 13, 13, 13, 17, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 74, 5 ], [ 74, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 32, 43 ], [ 43, 44 ], [ 44, 45 ], [ 46, 46 ], [ 46, 47 ], [ 46, 48 ], [ 46, 49 ], [ 44, 50 ], [ 43, 51 ], [ 51, 52 ], [ 52, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 52, 57 ], [ 43, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 59, 64 ], [ 64, 65 ], [ 64, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 6, 71 ], [ 71, 72 ], [ 0, 73 ], [ 73, 74 ], [ 73, 75 ] ]
[ "import java.util.*;\n\npublic class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }", "a >= k", "a", "k", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }", "k-a-b < 0", "k-a-b", "k-a-b", "k", "a", "b", "0", "{\n System.out.println(a);\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n System.out.println(a-(k-a-b));\n }", "System.out.println(a-(k-a-b))", "System.out.println", "System.out", "System", "System.out", "a-(k-a-b)", "a", "(k-a-b)", "k-a-b", "k", "a", "b", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if(a >= k){\n System.out.println(k);\n }else if(k-a-b < 0){\n System.out.println(a);\n }else{\n System.out.println(a-(k-a-b));\n }\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); if(a >= k){ System.out.println(k); }else if(k-a-b < 0){ System.out.println(a); }else{ System.out.println(a-(k-a-b)); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 13, 13, 30, 0, 13, 2, 13, 17, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 47, 52 ], [ 52, 53 ], [ 52, 54 ], [ 47, 55 ], [ 55, 56 ], [ 56, 57 ], [ 47, 58 ], [ 59, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 67, 68 ], [ 67, 69 ], [ 60, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 73, 74 ], [ 73, 75 ], [ 70, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 70, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 8, 86 ], [ 86, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 86, 91 ], [ 6, 92 ], [ 92, 93 ] ]
[ "import java.util.*;\nclass Main{\n public static void main(String args[]){\n Scanner scanner = new Scanner(System.in);\n int plusOne = Integer.parseInt(scanner.next());\n int zero = Integer.parseInt(scanner.next());\n\t int minusOne = Integer.parseInt(scanner.next());\n \tint amount = Integer.parseInt(scanner.next());\n\t\tint ans = 0;\n for (int i=0; i<amount; i++) {\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }\n\n System.out.println(ans);\n\n }\n}", "import java.util.*;", "util.*", "java", "class Main{\n public static void main(String args[]){\n Scanner scanner = new Scanner(System.in);\n int plusOne = Integer.parseInt(scanner.next());\n int zero = Integer.parseInt(scanner.next());\n\t int minusOne = Integer.parseInt(scanner.next());\n \tint amount = Integer.parseInt(scanner.next());\n\t\tint ans = 0;\n for (int i=0; i<amount; i++) {\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }\n\n System.out.println(ans);\n\n }\n}", "Main", "public static void main(String args[]){\n Scanner scanner = new Scanner(System.in);\n int plusOne = Integer.parseInt(scanner.next());\n int zero = Integer.parseInt(scanner.next());\n\t int minusOne = Integer.parseInt(scanner.next());\n \tint amount = Integer.parseInt(scanner.next());\n\t\tint ans = 0;\n for (int i=0; i<amount; i++) {\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }\n\n System.out.println(ans);\n\n }", "main", "{\n Scanner scanner = new Scanner(System.in);\n int plusOne = Integer.parseInt(scanner.next());\n int zero = Integer.parseInt(scanner.next());\n\t int minusOne = Integer.parseInt(scanner.next());\n \tint amount = Integer.parseInt(scanner.next());\n\t\tint ans = 0;\n for (int i=0; i<amount; i++) {\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }\n\n System.out.println(ans);\n\n }", "Scanner scanner = new Scanner(System.in);", "scanner", "new Scanner(System.in)", "int plusOne = Integer.parseInt(scanner.next());", "plusOne", "Integer.parseInt(scanner.next())", "Integer.parseInt", "Integer", "scanner.next()", "scanner.next", "scanner", "int zero = Integer.parseInt(scanner.next());", "zero", "Integer.parseInt(scanner.next())", "Integer.parseInt", "Integer", "scanner.next()", "scanner.next", "scanner", "int minusOne = Integer.parseInt(scanner.next());", "minusOne", "Integer.parseInt(scanner.next())", "Integer.parseInt", "Integer", "scanner.next()", "scanner.next", "scanner", "int amount = Integer.parseInt(scanner.next());", "amount", "Integer.parseInt(scanner.next())", "Integer.parseInt", "Integer", "scanner.next()", "scanner.next", "scanner", "int ans = 0;", "ans", "0", "for (int i=0; i<amount; i++) {\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }", "int i=0;", "int i=0;", "i", "0", "i<amount", "i", "amount", "i++", "i++", "i", "{\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }", "{\n \tif (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }\n }", "if (i < plusOne) {\n \tans = ans + 1;\n } else if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }", "i < plusOne", "i", "plusOne", "{\n \tans = ans + 1;\n }", "ans = ans + 1", "ans", "ans + 1", "ans", "1", "if (i < plusOne + zero) {\n \tans = ans;\n } else {\n \tans = ans - 1;\n }", "i < plusOne + zero", "i", "plusOne + zero", "plusOne", "zero", "{\n \tans = ans;\n }", "ans = ans", "ans", "ans", "{\n \tans = ans - 1;\n }", "ans = ans - 1", "ans", "ans - 1", "ans", "1", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String args[]", "args" ]
import java.util.*; class Main{ public static void main(String args[]){ Scanner scanner = new Scanner(System.in); int plusOne = Integer.parseInt(scanner.next()); int zero = Integer.parseInt(scanner.next()); int minusOne = Integer.parseInt(scanner.next()); int amount = Integer.parseInt(scanner.next()); int ans = 0; for (int i=0; i<amount; i++) { if (i < plusOne) { ans = ans + 1; } else if (i < plusOne + zero) { ans = ans; } else { ans = ans - 1; } } System.out.println(ans); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 41, 13, 17, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 4, 18, 13, 13, 23, 13, 23, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 0, 13, 17, 23, 13, 12, 13, 30, 38, 5, 13, 30, 37, 20, 30, 29, 4, 18, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 22, 23 ], [ 22, 24 ], [ 0, 25 ], [ 25, 26 ], [ 25, 27 ], [ 0, 28 ], [ 28, 29 ], [ 28, 30 ], [ 0, 31 ], [ 31, 32 ], [ 31, 33 ], [ 0, 34 ], [ 34, 35 ], [ 34, 36 ], [ 0, 37 ], [ 37, 38 ], [ 37, 39 ], [ 0, 40 ], [ 40, 41 ], [ 40, 42 ], [ 0, 43 ], [ 43, 44 ], [ 43, 45 ], [ 0, 46 ], [ 46, 47 ], [ 46, 48 ], [ 0, 49 ], [ 49, 50 ], [ 49, 51 ], [ 0, 52 ], [ 52, 53 ], [ 52, 54 ], [ 0, 55 ], [ 55, 56 ], [ 55, 57 ], [ 0, 58 ], [ 58, 59 ], [ 58, 60 ], [ 0, 61 ], [ 61, 62 ], [ 61, 63 ], [ 0, 64 ], [ 64, 65 ], [ 64, 66 ], [ 0, 67 ], [ 67, 68 ], [ 67, 69 ], [ 0, 70 ], [ 70, 71 ], [ 70, 72 ], [ 0, 73 ], [ 276, 74 ], [ 276, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 80, 82 ], [ 77, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 85, 87 ], [ 77, 88 ], [ 88, 89 ], [ 88, 90 ], [ 77, 91 ], [ 91, 92 ], [ 91, 93 ], [ 77, 94 ], [ 94, 95 ], [ 94, 96 ], [ 77, 97 ], [ 97, 98 ], [ 98, 99 ], [ 97, 100 ], [ 97, 101 ], [ 97, 102 ], [ 77, 103 ], [ 103, 104 ], [ 104, 105 ], [ 75, 106 ], [ 106, 107 ], [ 0, 108 ], [ 108, 109 ], [ 108, 110 ], [ 110, 111 ], [ 110, 112 ], [ 108, 113 ], [ 113, 114 ], [ 113, 115 ], [ 115, 116 ], [ 116, 117 ], [ 116, 118 ], [ 118, 119 ], [ 119, 120 ], [ 115, 121 ], [ 121, 122 ], [ 121, 123 ], [ 123, 124 ], [ 124, 125 ], [ 115, 126 ], [ 126, 127 ], [ 126, 128 ], [ 128, 129 ], [ 129, 130 ], [ 115, 131 ], [ 131, 132 ], [ 131, 133 ], [ 133, 134 ], [ 134, 135 ], [ 115, 136 ], [ 136, 137 ], [ 136, 138 ], [ 115, 139 ], [ 139, 140 ], [ 140, 141 ], [ 140, 142 ], [ 139, 143 ], [ 143, 144 ], [ 144, 145 ], [ 144, 146 ], [ 143, 147 ], [ 147, 148 ], [ 147, 149 ], [ 139, 150 ], [ 150, 151 ], [ 151, 152 ], [ 151, 153 ], [ 150, 154 ], [ 154, 155 ], [ 154, 156 ], [ 115, 157 ], [ 157, 158 ], [ 158, 159 ], [ 158, 160 ], [ 157, 161 ], [ 161, 162 ], [ 162, 163 ], [ 162, 164 ], [ 157, 165 ], [ 165, 166 ], [ 166, 167 ], [ 166, 168 ], [ 115, 169 ], [ 169, 170 ], [ 170, 171 ], [ 170, 172 ], [ 169, 173 ], [ 173, 174 ], [ 174, 175 ], [ 174, 176 ], [ 173, 177 ], [ 177, 178 ], [ 177, 179 ], [ 169, 180 ], [ 180, 181 ], [ 181, 182 ], [ 181, 183 ], [ 180, 184 ], [ 184, 185 ], [ 184, 186 ], [ 115, 187 ], [ 187, 188 ], [ 188, 189 ], [ 187, 190 ], [ 113, 191 ], [ 191, 192 ], [ 113, 193 ], [ 193, 194 ], [ 113, 195 ], [ 195, 196 ], [ 0, 197 ], [ 197, 198 ], [ 197, 199 ], [ 199, 200 ], [ 197, 201 ], [ 201, 202 ], [ 197, 203 ], [ 203, 204 ], [ 203, 205 ], [ 205, 206 ], [ 206, 207 ], [ 206, 208 ], [ 205, 209 ], [ 209, 210 ], [ 209, 211 ], [ 203, 212 ], [ 212, 213 ], [ 197, 214 ], [ 214, 215 ], [ 214, 216 ], [ 216, 217 ], [ 217, 218 ], [ 218, 219 ], [ 218, 220 ], [ 220, 221 ], [ 221, 222 ], [ 217, 223 ], [ 223, 224 ], [ 224, 225 ], [ 225, 226 ], [ 226, 227 ], [ 197, 228 ], [ 228, 229 ], [ 228, 230 ], [ 230, 231 ], [ 231, 232 ], [ 232, 233 ], [ 233, 234 ], [ 233, 235 ], [ 232, 236 ], [ 236, 237 ], [ 237, 238 ], [ 238, 239 ], [ 231, 240 ], [ 240, 241 ], [ 241, 242 ], [ 241, 243 ], [ 230, 244 ], [ 244, 245 ], [ 245, 246 ], [ 246, 247 ], [ 197, 248 ], [ 248, 249 ], [ 248, 250 ], [ 250, 251 ], [ 251, 252 ], [ 252, 253 ], [ 253, 254 ], [ 252, 255 ], [ 255, 256 ], [ 197, 257 ], [ 257, 258 ], [ 257, 259 ], [ 259, 260 ], [ 260, 261 ], [ 261, 262 ], [ 262, 263 ], [ 261, 264 ], [ 264, 265 ], [ 197, 266 ], [ 266, 267 ], [ 266, 268 ], [ 268, 269 ], [ 269, 270 ], [ 270, 271 ], [ 271, 272 ], [ 270, 273 ], [ 273, 274 ], [ 0, 275 ], [ 275, 276 ], [ 275, 277 ] ]
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.InputStreamReader;\nimport java.io.OutputStream;\nimport java.io.PrintWriter;\nimport java.text.SimpleDateFormat;\nimport java.util.ArrayList;\nimport java.util.Arrays;\nimport java.util.Collections;\nimport java.util.Comparator;\nimport java.util.Date;\nimport java.util.HashMap;\nimport java.util.HashSet;\nimport java.util.LinkedList;\nimport java.util.List;\nimport java.util.Map;\nimport java.util.Queue;\nimport java.util.Set;\nimport java.util.StringTokenizer;\nimport java.util.TreeSet;\n\nimport static java.util.Arrays.binarySearch;\nimport static java.util.Arrays.copyOfRange;\nimport static java.util.Arrays.sort;\n\npublic class Main {\n\n public static void main(String[] args) throws Exception {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n}\n\nclass Task {\n\n private static int mod = 998244353;\n\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n int ans = 0;\n if (k > a) {\n ans += a;\n k -= a;\n } else {\n ans += k;\n k = 0;\n }\n if (k > b) {\n k -= b;\n } else {\n k = 0;\n }\n if (k > c) {\n ans -= c;\n k -= c;\n } else {\n ans -= k;\n k = 0;\n }\n out.println(ans);\n }\n\n}\n\nclass InputReader {\n\n private final BufferedReader reader;\n private StringTokenizer tokenizer;\n\n public InputReader(InputStream stream) {\n reader = new BufferedReader(new InputStreamReader(stream));\n tokenizer = null;\n }\n\n public String nextLine() {\n try {\n return reader.readLine();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }\n\n public String next() {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(nextLine());\n }\n return tokenizer.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(next());\n }\n\n public long nextLong() {\n return Long.parseLong(next());\n }\n\n public double nextDouble() {\n return Double.parseDouble(next());\n }\n\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.text.SimpleDateFormat;", "SimpleDateFormat", "java.text", "import java.util.ArrayList;", "ArrayList", "java.util", "import java.util.Arrays;", "Arrays", "java.util", "import java.util.Collections;", "Collections", "java.util", "import java.util.Comparator;", "Comparator", "java.util", "import java.util.Date;", "Date", "java.util", "import java.util.HashMap;", "HashMap", "java.util", "import java.util.HashSet;", "HashSet", "java.util", "import java.util.LinkedList;", "LinkedList", "java.util", "import java.util.List;", "List", "java.util", "import java.util.Map;", "Map", "java.util", "import java.util.Queue;", "Queue", "java.util", "import java.util.Set;", "Set", "java.util", "import java.util.StringTokenizer;", "StringTokenizer", "java.util", "import java.util.TreeSet;", "TreeSet", "java.util", "import static java.util.Arrays.binarySearch;", "import static java.util.Arrays.binarySearch;", "import static java.util.Arrays.binarySearch;", "import static java.util.Arrays.copyOfRange;", "import static java.util.Arrays.copyOfRange;", "import static java.util.Arrays.copyOfRange;", "import static java.util.Arrays.sort;", "import static java.util.Arrays.sort;", "import static java.util.Arrays.sort;", "public class Main {\n\n public static void main(String[] args) throws Exception {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n}", "Main", "public static void main(String[] args) throws Exception {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "InputReader in = new InputReader(inputStream);", "in", "new InputReader(inputStream)", "PrintWriter out = new PrintWriter(outputStream);", "out", "new PrintWriter(outputStream)", "Task solver = new Task();", "solver", "new Task()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "class Task {\n\n private static int mod = 998244353;\n\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n int ans = 0;\n if (k > a) {\n ans += a;\n k -= a;\n } else {\n ans += k;\n k = 0;\n }\n if (k > b) {\n k -= b;\n } else {\n k = 0;\n }\n if (k > c) {\n ans -= c;\n k -= c;\n } else {\n ans -= k;\n k = 0;\n }\n out.println(ans);\n }\n\n}", "Task", "private static int mod = 998244353;", "mod", "998244353", "public void solve(int testNumber, InputReader in, PrintWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n int ans = 0;\n if (k > a) {\n ans += a;\n k -= a;\n } else {\n ans += k;\n k = 0;\n }\n if (k > b) {\n k -= b;\n } else {\n k = 0;\n }\n if (k > c) {\n ans -= c;\n k -= c;\n } else {\n ans -= k;\n k = 0;\n }\n out.println(ans);\n }", "solve", "{\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n int ans = 0;\n if (k > a) {\n ans += a;\n k -= a;\n } else {\n ans += k;\n k = 0;\n }\n if (k > b) {\n k -= b;\n } else {\n k = 0;\n }\n if (k > c) {\n ans -= c;\n k -= c;\n } else {\n ans -= k;\n k = 0;\n }\n out.println(ans);\n }", "int a = in.nextInt();", "a", "in.nextInt()", "in.nextInt", "in", "int b = in.nextInt();", "b", "in.nextInt()", "in.nextInt", "in", "int c = in.nextInt();", "c", "in.nextInt()", "in.nextInt", "in", "int k = in.nextInt();", "k", "in.nextInt()", "in.nextInt", "in", "int ans = 0;", "ans", "0", "if (k > a) {\n ans += a;\n k -= a;\n } else {\n ans += k;\n k = 0;\n }", "k > a", "k", "a", "{\n ans += a;\n k -= a;\n }", "ans += a", "ans", "a", "k -= a", "k", "a", "{\n ans += k;\n k = 0;\n }", "ans += k", "ans", "k", "k = 0", "k", "0", "if (k > b) {\n k -= b;\n } else {\n k = 0;\n }", "k > b", "k", "b", "{\n k -= b;\n }", "k -= b", "k", "b", "{\n k = 0;\n }", "k = 0", "k", "0", "if (k > c) {\n ans -= c;\n k -= c;\n } else {\n ans -= k;\n k = 0;\n }", "k > c", "k", "c", "{\n ans -= c;\n k -= c;\n }", "ans -= c", "ans", "c", "k -= c", "k", "c", "{\n ans -= k;\n k = 0;\n }", "ans -= k", "ans", "k", "k = 0", "k", "0", "out.println(ans)", "out.println", "out", "ans", "int testNumber", "testNumber", "InputReader in", "in", "PrintWriter out", "out", "class InputReader {\n\n private final BufferedReader reader;\n private StringTokenizer tokenizer;\n\n public InputReader(InputStream stream) {\n reader = new BufferedReader(new InputStreamReader(stream));\n tokenizer = null;\n }\n\n public String nextLine() {\n try {\n return reader.readLine();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }\n\n public String next() {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(nextLine());\n }\n return tokenizer.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(next());\n }\n\n public long nextLong() {\n return Long.parseLong(next());\n }\n\n public double nextDouble() {\n return Double.parseDouble(next());\n }\n\n}", "InputReader", "private final BufferedReader reader;", "reader", "private StringTokenizer tokenizer;", "tokenizer", "public InputReader(InputStream stream) {\n reader = new BufferedReader(new InputStreamReader(stream));\n tokenizer = null;\n }", "InputReader", "{\n reader = new BufferedReader(new InputStreamReader(stream));\n tokenizer = null;\n }", "reader = new BufferedReader(new InputStreamReader(stream))", "reader", "new BufferedReader(new InputStreamReader(stream))", "tokenizer = null", "tokenizer", "null", "InputStream stream", "stream", "public String nextLine() {\n try {\n return reader.readLine();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }", "nextLine", "{\n try {\n return reader.readLine();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }", "try {\n return reader.readLine();\n } catch (IOException e) {\n throw new RuntimeException(e);\n }", "catch (IOException e) {\n throw new RuntimeException(e);\n }", "IOException e", "{\n throw new RuntimeException(e);\n }", "throw new RuntimeException(e);", "new RuntimeException(e)", "{\n return reader.readLine();\n }", "return reader.readLine();", "reader.readLine()", "reader.readLine", "reader", "public String next() {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(nextLine());\n }\n return tokenizer.nextToken();\n }", "next", "{\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(nextLine());\n }\n return tokenizer.nextToken();\n }", "while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(nextLine());\n }", "tokenizer == null || !tokenizer.hasMoreTokens()", "tokenizer == null", "tokenizer", "null", "!tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens", "tokenizer", "{\n tokenizer = new StringTokenizer(nextLine());\n }", "tokenizer = new StringTokenizer(nextLine())", "tokenizer", "new StringTokenizer(nextLine())", "return tokenizer.nextToken();", "tokenizer.nextToken()", "tokenizer.nextToken", "tokenizer", "public int nextInt() {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "public long nextLong() {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "public double nextDouble() {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "public class Main {\n\n public static void main(String[] args) throws Exception {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n}", "public class Main {\n\n public static void main(String[] args) throws Exception {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n\n Task solver = new Task();\n solver.solve(1, in, out);\n out.close();\n }\n}", "Main" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.io.OutputStream; import java.io.PrintWriter; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.Comparator; import java.util.Date; import java.util.HashMap; import java.util.HashSet; import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Queue; import java.util.Set; import java.util.StringTokenizer; import java.util.TreeSet; import static java.util.Arrays.binarySearch; import static java.util.Arrays.copyOfRange; import static java.util.Arrays.sort; public class Main { public static void main(String[] args) throws Exception { InputStream inputStream = System.in; OutputStream outputStream = System.out; InputReader in = new InputReader(inputStream); PrintWriter out = new PrintWriter(outputStream); Task solver = new Task(); solver.solve(1, in, out); out.close(); } } class Task { private static int mod = 998244353; public void solve(int testNumber, InputReader in, PrintWriter out) { int a = in.nextInt(); int b = in.nextInt(); int c = in.nextInt(); int k = in.nextInt(); int ans = 0; if (k > a) { ans += a; k -= a; } else { ans += k; k = 0; } if (k > b) { k -= b; } else { k = 0; } if (k > c) { ans -= c; k -= c; } else { ans -= k; k = 0; } out.println(ans); } } class InputReader { private final BufferedReader reader; private StringTokenizer tokenizer; public InputReader(InputStream stream) { reader = new BufferedReader(new InputStreamReader(stream)); tokenizer = null; } public String nextLine() { try { return reader.readLine(); } catch (IOException e) { throw new RuntimeException(e); } } public String next() { while (tokenizer == null || !tokenizer.hasMoreTokens()) { tokenizer = new StringTokenizer(nextLine()); } return tokenizer.nextToken(); } public int nextInt() { return Integer.parseInt(next()); } public long nextLong() { return Long.parseLong(next()); } public double nextDouble() { return Double.parseDouble(next()); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 13, 17, 30, 0, 13, 17, 0, 13, 17, 14, 2, 13, 17, 30, 0, 13, 17, 30, 0, 13, 17, 0, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 86, 5 ], [ 86, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 38, 43 ], [ 43, 44 ], [ 43, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 38, 49 ], [ 50, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 55, 59 ], [ 59, 60 ], [ 59, 61 ], [ 51, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 62, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 74, 75 ], [ 74, 76 ], [ 8, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 6, 83 ], [ 83, 84 ], [ 0, 85 ], [ 85, 86 ], [ 85, 87 ] ]
[ "import java.util.*;\n\npublic class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n } \n}", "import java.util.*;", "util.*", "java", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n } \n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int D = sc.nextInt();", "D", "sc.nextInt()", "sc.nextInt", "sc", "sc.close()", "sc.close", "sc", "int result = 0;", "result", "0", "for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < D", "i", "D", "i++", "i++", "i", "{\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }", "{\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }", "if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }", "A > 0", "A", "0", "{\n result += 1;\n A -= 1;\n }", "result += 1", "result", "1", "A -= 1", "A", "1", "if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }", "B > 0", "B", "0", "{\n B -= 1;\n }", "B -= 1", "B", "1", "{\n result -= 1;\n C -= 1;\n }", "result -= 1", "result", "1", "C -= 1", "C", "1", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "String[] args", "args", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n } \n}", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int D = sc.nextInt();\n sc.close();\n \n int result = 0;\n \n for(int i = 0; i < D; i++){\n if (A > 0){\n result += 1;\n A -= 1;\n } else if ( B > 0){\n B -= 1;\n } else {\n result -= 1;\n C -= 1;\n }\n }\n System.out.println(result);\n } \n}", "Main" ]
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int D = sc.nextInt(); sc.close(); int result = 0; for(int i = 0; i < D; i++){ if (A > 0){ result += 1; A -= 1; } else if ( B > 0){ B -= 1; } else { result -= 1; C -= 1; } } System.out.println(result); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 41, 13, 17, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 0, 13, 2, 13, 13, 14, 2, 13, 17, 30, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 0, 13, 2, 13, 13, 14, 2, 13, 17, 30, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 148, 5 ], [ 148, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 38, 40 ], [ 8, 41 ], [ 41, 42 ], [ 41, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 44, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 44, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 8, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 8, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 8, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 69, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 69, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 8, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 8, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 8, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 94, 102 ], [ 102, 103 ], [ 103, 104 ], [ 103, 105 ], [ 8, 106 ], [ 106, 107 ], [ 106, 108 ], [ 8, 109 ], [ 109, 110 ], [ 110, 111 ], [ 111, 112 ], [ 111, 113 ], [ 109, 114 ], [ 114, 115 ], [ 114, 116 ], [ 109, 117 ], [ 117, 118 ], [ 118, 119 ], [ 109, 120 ], [ 121, 121 ], [ 121, 122 ], [ 122, 123 ], [ 8, 124 ], [ 124, 125 ], [ 125, 126 ], [ 126, 127 ], [ 126, 128 ], [ 124, 129 ], [ 129, 130 ], [ 129, 131 ], [ 124, 132 ], [ 132, 133 ], [ 133, 134 ], [ 124, 135 ], [ 136, 136 ], [ 136, 137 ], [ 137, 138 ], [ 8, 139 ], [ 139, 140 ], [ 140, 141 ], [ 141, 142 ], [ 141, 143 ], [ 139, 144 ], [ 6, 145 ], [ 145, 146 ], [ 0, 147 ], [ 147, 148 ], [ 147, 149 ] ]
[ "import java.util.Scanner;\n\npublic class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }\n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int card1 = sc.nextInt();", "card1", "sc.nextInt()", "sc.nextInt", "sc", "int card2 = sc.nextInt();", "card2", "sc.nextInt()", "sc.nextInt", "sc", "int card3 = sc.nextInt();", "card3", "sc.nextInt()", "sc.nextInt", "sc", "int card = sc.nextInt();", "card", "sc.nextInt()", "sc.nextInt", "sc", "sc.close()", "sc.close", "sc", "int i = 0;", "i", "0", "int j = 0;", "j", "0", "int k = 0;", "k", "0", "if(card>card1){\n i=card1;\n }else{\n i=card;\n }", "card>card1", "card", "card1", "{\n i=card1;\n }", "i=card1", "i", "card1", "{\n i=card;\n }", "i=card", "i", "card", "card=card-card1", "card", "card-card1", "card", "card1", "if(card<0){\n card=0;\n }", "card<0", "card", "0", "{\n card=0;\n }", "card=0", "card", "0", "if(card>card2){\n j=card2;\n }else{\n j=card;\n }", "card>card2", "card", "card2", "{\n j=card2;\n }", "j=card2", "j", "card2", "{\n j=card;\n }", "j=card", "j", "card", "card=card-card2", "card", "card-card2", "card", "card2", "if(card<0){\n card=0;\n }", "card<0", "card", "0", "{\n card=0;\n }", "card=0", "card", "0", "if(card>card3){\n k=card3;\n }else{\n k=card;\n }", "card>card3", "card", "card3", "{\n k=card3;\n }", "k=card3", "k", "card3", "{\n k=card;\n }", "k=card", "k", "card", "int ans=0;", "ans", "0", "for(int num1=0;num1<i; num1++){\n ans++;\n }", "int num1=0;", "int num1=0;", "num1", "0", "num1<i", "num1", "i", "num1++", "num1++", "num1", "{\n ans++;\n }", "{\n ans++;\n }", "ans++", "ans", "for(int num2=0; num2<k; num2++){\n ans --;\n }", "int num2=0;", "int num2=0;", "num2", "0", "num2<k", "num2", "k", "num2++", "num2++", "num2", "{\n ans --;\n }", "{\n ans --;\n }", "ans --", "ans", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }\n}", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int card1 = sc.nextInt();\n int card2 = sc.nextInt();\n int card3 = sc.nextInt();\n int card = sc.nextInt();\n sc.close();\n\n int i = 0;\n int j = 0;\n int k = 0;\n if(card>card1){\n i=card1;\n }else{\n i=card;\n }\n card=card-card1;\n if(card<0){\n card=0;\n }\n if(card>card2){\n j=card2;\n }else{\n j=card;\n }\n card=card-card2;\n if(card<0){\n card=0;\n }\n if(card>card3){\n k=card3;\n }else{\n k=card;\n }\n int ans=0;\n for(int num1=0;num1<i; num1++){\n ans++;\n }\n for(int num2=0; num2<k; num2++){\n ans --;\n }\n System.out.println(ans);\n }\n}", "Main" ]
import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int card1 = sc.nextInt(); int card2 = sc.nextInt(); int card3 = sc.nextInt(); int card = sc.nextInt(); sc.close(); int i = 0; int j = 0; int k = 0; if(card>card1){ i=card1; }else{ i=card; } card=card-card1; if(card<0){ card=0; } if(card>card2){ j=card2; }else{ j=card; } card=card-card2; if(card<0){ card=0; } if(card>card3){ k=card3; }else{ k=card; } int ans=0; for(int num1=0;num1<i; num1++){ ans++; } for(int num2=0; num2<k; num2++){ ans --; } System.out.println(ans); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 4, 18, 4, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 116, 8 ], [ 116, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 19, 20 ], [ 20, 21 ], [ 21, 22 ], [ 22, 23 ], [ 17, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 27, 30 ], [ 30, 31 ], [ 30, 32 ], [ 11, 33 ], [ 33, 34 ], [ 33, 35 ], [ 35, 36 ], [ 36, 37 ], [ 35, 38 ], [ 38, 39 ], [ 38, 40 ], [ 11, 41 ], [ 41, 42 ], [ 41, 43 ], [ 43, 44 ], [ 44, 45 ], [ 43, 46 ], [ 46, 47 ], [ 46, 48 ], [ 11, 49 ], [ 49, 50 ], [ 49, 51 ], [ 51, 52 ], [ 52, 53 ], [ 51, 54 ], [ 54, 55 ], [ 54, 56 ], [ 11, 57 ], [ 57, 58 ], [ 57, 59 ], [ 11, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 64, 68 ], [ 68, 69 ], [ 68, 70 ], [ 60, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 71, 75 ], [ 75, 76 ], [ 75, 77 ], [ 11, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 78, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 78, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 11, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 90, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 98, 100 ], [ 90, 101 ], [ 101, 102 ], [ 102, 103 ], [ 102, 104 ], [ 104, 105 ], [ 104, 106 ], [ 11, 107 ], [ 107, 108 ], [ 108, 109 ], [ 109, 110 ], [ 109, 111 ], [ 107, 112 ], [ 9, 113 ], [ 113, 114 ], [ 0, 115 ], [ 115, 116 ], [ 115, 117 ] ]
[ "import java.util.*;\nimport java.io.*;\npublic class Main\n{\n \n\tpublic static void main(String[] args) throws Exception{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}\n}\n", "import java.util.*;", "util.*", "java", "import java.io.*;", "io.*", "java", "public class Main\n{\n \n\tpublic static void main(String[] args) throws Exception{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}\n}", "Main", "public static void main(String[] args) throws Exception{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}", "main", "{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}", "BufferedReader br = new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "String[] s = br.readLine().trim().split(\" \");", "s", "br.readLine().trim().split(\" \")", "br.readLine().trim().split", "br.readLine().trim()", "br.readLine().trim", "br.readLine()", "br.readLine", "br", "\" \"", "int a = Integer.parseInt(s[0]);", "a", "Integer.parseInt(s[0])", "Integer.parseInt", "Integer", "s[0]", "s", "0", "int b = Integer.parseInt(s[1]);", "b", "Integer.parseInt(s[1])", "Integer.parseInt", "Integer", "s[1]", "s", "1", "int c = Integer.parseInt(s[2]);", "c", "Integer.parseInt(s[2])", "Integer.parseInt", "Integer", "s[2]", "s", "2", "int k = Integer.parseInt(s[3]);", "k", "Integer.parseInt(s[3])", "Integer.parseInt", "Integer", "s[3]", "s", "3", "int ans = 0;", "ans", "0", "if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }", "k >= a", "k", "a", "{\n\t ans += a;\n\t k -= a;\n\t }", "ans += a", "ans", "a", "k -= a", "k", "a", "{\n\t ans = k;\n\t k = 0;\n\t }", "ans = k", "ans", "k", "k = 0", "k", "0", "if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }", "k >= b", "k", "b", "{\n\t k -= b;\n\t }", "k -= b", "k", "b", "{\n\t k = 0;\n\t }", "k = 0", "k", "0", "if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }", "k >= c", "k", "c", "{\n\t ans -= c;\n\t k -= c;\n\t }", "ans -= c", "ans", "c", "k -= c", "k", "c", "{\n\t ans = ans-k;\n\t }", "ans = ans-k", "ans", "ans-k", "ans", "k", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main\n{\n \n\tpublic static void main(String[] args) throws Exception{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}\n}", "public class Main\n{\n \n\tpublic static void main(String[] args) throws Exception{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString[] s = br.readLine().trim().split(\" \");\n\t\tint a = Integer.parseInt(s[0]);\n\t\tint b = Integer.parseInt(s[1]);\n\t\tint c = Integer.parseInt(s[2]);\n\t\tint k = Integer.parseInt(s[3]);\n\t\tint ans = 0;\n\t if(k >= a){\n\t ans += a;\n\t k -= a;\n\t }\n\t else{\n\t ans = k;\n\t k = 0;\n\t }\n\n\t if(k >= b){\n\t k -= b;\n\t }\n\t else{\n\t k = 0;\n\t }\n\t\n\t if(k >= c){\n\t ans -= c;\n\t k -= c;\n\t }\n\t else{\n\t ans = ans-k;\n\t }\n\t System.out.println(ans);\n\t}\n}", "Main" ]
import java.util.*; import java.io.*; public class Main { public static void main(String[] args) throws Exception{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String[] s = br.readLine().trim().split(" "); int a = Integer.parseInt(s[0]); int b = Integer.parseInt(s[1]); int c = Integer.parseInt(s[2]); int k = Integer.parseInt(s[3]); int ans = 0; if(k >= a){ ans += a; k -= a; } else{ ans = k; k = 0; } if(k >= b){ k -= b; } else{ k = 0; } if(k >= c){ ans -= c; k -= c; } else{ ans = ans-k; } System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 2, 13, 13, 2, 13, 17, 30, 0, 13, 13, 0, 13, 17, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 17, 14, 2, 2, 13, 13, 2, 13, 17, 30, 0, 13, 13, 14, 2, 13, 17, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 96, 5 ], [ 96, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 43, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 50, 52 ], [ 38, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 57, 59 ], [ 8, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 60, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 69, 73 ], [ 73, 74 ], [ 73, 75 ], [ 68, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 8, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 80, 84 ], [ 84, 85 ], [ 84, 86 ], [ 8, 87 ], [ 87, 88 ], [ 88, 89 ], [ 89, 90 ], [ 89, 91 ], [ 87, 92 ], [ 6, 93 ], [ 93, 94 ], [ 0, 95 ], [ 95, 96 ], [ 95, 97 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "Long A=sc.nextLong();", "A", "sc.nextLong()", "sc.nextLong", "sc", "Long B=sc.nextLong();", "B", "sc.nextLong()", "sc.nextLong", "sc", "Long C=sc.nextLong();", "C", "sc.nextLong()", "sc.nextLong", "sc", "Long K=sc.nextLong();", "K", "sc.nextLong()", "sc.nextLong", "sc", "sc.close()", "sc.close", "sc", "long point=0l;", "point", "0l", "if((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}", "(A>=K)&&K!=0l", "(A>=K)", "A", "K", "K!=0l", "K", "0l", "{\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}", "point=K", "point", "K", "K=0l", "K", "0l", "{\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}", "point+=A", "point", "A", "K-=A", "K", "A", "if((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}", "(B>=K)", "B", "K", "{\n\t\t\tK=0l;\n\t\t}", "K=0l", "K", "0l", "if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}", "(B<K)&&K!=0l", "(B<K)", "B", "K", "K!=0l", "K", "0l", "{\n\t\t\tK-=B;\n\t\t}", "K-=B", "K", "B", "if(K!=0l)\n\t\t\tpoint-=K;", "K!=0l", "K", "0l", "point-=K", "point", "K", "System.out.println(point)", "System.out.println", "System.out", "System", "System.out", "point", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tLong A=sc.nextLong();\n\t\tLong B=sc.nextLong();\n\t\tLong C=sc.nextLong();\n\t\tLong K=sc.nextLong();\n\t\tsc.close();\n\t\tlong point=0l;\n\t\t\n\t\tif((A>=K)&&K!=0l) {\n\t\t\tpoint=K;\n\t\t\tK=0l;\n\t\t}else {\n\t\t\tpoint+=A;\n\t\t\tK-=A;\n\t\t}\n\t\tif((B>=K)) {\n\t\t\tK=0l;\n\t\t}else if((B<K)&&K!=0l) {\n\t\t\tK-=B;\n\t\t}\n\t\tif(K!=0l)\n\t\t\tpoint-=K;\n\t\tSystem.out.println(point);\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); Long A=sc.nextLong(); Long B=sc.nextLong(); Long C=sc.nextLong(); Long K=sc.nextLong(); sc.close(); long point=0l; if((A>=K)&&K!=0l) { point=K; K=0l; }else { point+=A; K-=A; } if((B>=K)) { K=0l; }else if((B<K)&&K!=0l) { K-=B; } if(K!=0l) point-=K; System.out.println(point); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 13, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 13, 13, 0, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 77, 5 ], [ 77, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 8, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 37, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 37, 45 ], [ 45, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 45, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 45, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 60, 62 ], [ 55, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 65, 67 ], [ 8, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 6, 74 ], [ 74, 75 ], [ 0, 76 ], [ 76, 77 ], [ 76, 78 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }\n}", "Main", "public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }", "main", "{\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int point = 0;", "point", "0", "int diff;", "diff", "if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }", "A >= K", "A", "K", "{\n point = K;\n }", "point = K", "point", "K", "if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }", "(A + B) >= K", "(A + B)", "A", "B", "K", "{\n point = A;\n }", "point = A", "point", "A", "{\n diff = K - (A + B);\n point = A - diff;\n }", "diff = K - (A + B)", "diff", "K - (A + B)", "K", "(A + B)", "A", "B", "point = A - diff", "point", "A - diff", "A", "diff", "System.out.print(point)", "System.out.print", "System.out", "System", "System.out", "point", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }\n}", "public class Main {\n public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n int point = 0;\n int diff;\n\n if (A >= K) {\n point = K;\n } else if ((A + B) >= K) {\n point = A;\n } else {\n diff = K - (A + B);\n point = A - diff;\n }\n\n System.out.print(point);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int point = 0; int diff; if (A >= K) { point = K; } else if ((A + B) >= K) { point = A; } else { diff = K - (A + B); point = A - diff; } System.out.print(point); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 13, 13, 2, 13, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 2, 13, 13, 13, 2, 13, 2, 2, 13, 13, 13, 30, 0, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 44, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 50, 52 ], [ 43, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 43, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 59, 63 ], [ 58, 64 ], [ 64, 65 ], [ 64, 66 ], [ 67, 67 ], [ 67, 68 ], [ 67, 69 ], [ 67, 70 ], [ 57, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 76, 80 ], [ 8, 81 ], [ 81, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 81, 86 ], [ 6, 87 ], [ 87, 88 ] ]
[ "import java.util.*;\n\nclass Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int ans = 0;\n \n if( k<=a ){\n ans = k;\n }else if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }\n\n System.out.println( ans );\n\n }\n}", "import java.util.*;", "util.*", "java", "class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int ans = 0;\n \n if( k<=a ){\n ans = k;\n }else if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }\n\n System.out.println( ans );\n\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int ans = 0;\n \n if( k<=a ){\n ans = k;\n }else if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }\n\n System.out.println( ans );\n\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int ans = 0;\n \n if( k<=a ){\n ans = k;\n }else if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }\n\n System.out.println( ans );\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int ans = 0;", "ans", "0", "if( k<=a ){\n ans = k;\n }else if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }", "k<=a", "k", "a", "{\n ans = k;\n }", "ans = k", "ans", "k", "if( a<k & k<=a+b ){\n ans = a; \n }else if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }", "a<k & k<=a+b", "a<k", "a", "k", "k<=a+b", "k", "a+b", "a", "b", "{\n ans = a; \n }", "ans = a", "ans", "a", "if( a+b<k & k<=a+b+c){\n ans = a - (k-a-b);\n }", "a+b<k & k<=a+b+c", "a+b<k", "a+b", "a", "b", "k", "k<=a+b+c", "k", "a+b+c", "a+b+c", "a", "b", "c", "{\n ans = a - (k-a-b);\n }", "ans = a - (k-a-b)", "ans", "a - (k-a-b)", "a", "(k-a-b)", "k-a-b", "k", "a", "b", "System.out.println( ans )", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args" ]
import java.util.*; class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int ans = 0; if( k<=a ){ ans = k; }else if( a<k & k<=a+b ){ ans = a; }else if( a+b<k & k<=a+b+c){ ans = a - (k-a-b); } System.out.println( ans ); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 8, 2, 2, 13, 13, 13, 17, 2, 2, 13, 13, 13, 41, 13, 8, 2, 13, 13, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 65, 5 ], [ 65, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 34, 40 ], [ 34, 41 ], [ 42, 42 ], [ 42, 43 ], [ 42, 44 ], [ 42, 45 ], [ 8, 46 ], [ 46, 47 ], [ 46, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 48, 52 ], [ 48, 53 ], [ 8, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 54, 59 ], [ 59, 60 ], [ 59, 61 ], [ 6, 62 ], [ 62, 63 ], [ 0, 64 ], [ 64, 65 ], [ 64, 66 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }", "main", "{\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }", "Scanner scanner = new Scanner(System.in);", "scanner", "new Scanner(System.in)", "long A = scanner.nextInt();", "A", "scanner.nextInt()", "scanner.nextInt", "scanner", "long B = scanner.nextInt();", "B", "scanner.nextInt()", "scanner.nextInt", "scanner", "long C = scanner.nextInt();", "C", "scanner.nextInt()", "scanner.nextInt", "scanner", "long K = scanner.nextInt();", "K", "scanner.nextInt()", "scanner.nextInt", "scanner", "long minus = A + B >= K ? 0 : K - A - B;", "minus", "A + B >= K ? 0 : K - A - B", "A + B >= K", "A + B", "A", "B", "K", "0", "K - A - B", "K - A - B", "K", "A", "B", "long plus = A >= K ? K : A;", "plus", "A >= K ? K : A", "A >= K", "A", "K", "K", "A", "System.out.println(plus - minus)", "System.out.println", "System.out", "System", "System.out", "plus - minus", "plus", "minus", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextInt();\n long B = scanner.nextInt();\n long C = scanner.nextInt();\n long K = scanner.nextInt();\n long minus = A + B >= K ? 0 : K - A - B;\n long plus = A >= K ? K : A;\n System.out.println(plus - minus);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); long A = scanner.nextInt(); long B = scanner.nextInt(); long C = scanner.nextInt(); long K = scanner.nextInt(); long minus = A + B >= K ? 0 : K - A - B; long plus = A >= K ? K : A; System.out.println(plus - minus); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 72, 5 ], [ 72, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 32, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 50, 55 ], [ 43, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 57, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 64, 68 ], [ 6, 69 ], [ 69, 70 ], [ 0, 71 ], [ 71, 72 ], [ 71, 73 ] ]
[ "import java.util.*;\n\npublic class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }\n}", "Main", "public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "long K = sc.nextLong();", "K", "sc.nextLong()", "sc.nextLong", "sc", "if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }", "K <= A", "K", "A", "{\n System.out.println(K);\n }", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }", "K < A+B", "K", "A+B", "A", "B", "{\n System.out.println(A);\n }", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "{\n System.out.println(A-(K-A-B));\n }", "System.out.println(A-(K-A-B))", "System.out.println", "System.out", "System", "System.out", "A-(K-A-B)", "A", "(K-A-B)", "K-A-B", "K", "A", "B", "String[] args", "args", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }\n}", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n long K = sc.nextLong();\n \n if(K <= A) {\n System.out.println(K);\n } else if(K < A+B) {\n System.out.println(A);\n } else {\n System.out.println(A-(K-A-B));\n }\n\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args ) throws Exception { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); long K = sc.nextLong(); if(K <= A) { System.out.println(K); } else if(K < A+B) { System.out.println(A); } else { System.out.println(A-(K-A-B)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 0, 13, 4, 18, 13, 13, 4, 18, 13, 13, 17, 0, 13, 13, 0, 13, 13, 0, 13, 4, 18, 13, 13, 4, 18, 13, 13, 17, 4, 18, 13, 13, 23, 13, 23, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 118, 17 ], [ 118, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 21, 23 ], [ 23, 24 ], [ 23, 25 ], [ 20, 26 ], [ 26, 27 ], [ 26, 28 ], [ 28, 29 ], [ 28, 30 ], [ 20, 31 ], [ 31, 32 ], [ 31, 33 ], [ 20, 34 ], [ 34, 35 ], [ 34, 36 ], [ 20, 37 ], [ 37, 38 ], [ 37, 39 ], [ 20, 40 ], [ 40, 41 ], [ 41, 42 ], [ 40, 43 ], [ 40, 44 ], [ 40, 45 ], [ 20, 46 ], [ 46, 47 ], [ 47, 48 ], [ 18, 49 ], [ 49, 50 ], [ 118, 51 ], [ 51, 52 ], [ 51, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 59, 60 ], [ 55, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 64, 65 ], [ 55, 66 ], [ 66, 67 ], [ 66, 68 ], [ 68, 69 ], [ 69, 70 ], [ 55, 71 ], [ 71, 72 ], [ 71, 73 ], [ 73, 74 ], [ 74, 75 ], [ 55, 76 ], [ 76, 77 ], [ 76, 78 ], [ 55, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 82, 83 ], [ 81, 84 ], [ 81, 85 ], [ 85, 86 ], [ 86, 87 ], [ 85, 88 ], [ 85, 89 ], [ 55, 90 ], [ 90, 91 ], [ 90, 92 ], [ 55, 93 ], [ 93, 94 ], [ 93, 95 ], [ 55, 96 ], [ 96, 97 ], [ 96, 98 ], [ 98, 99 ], [ 99, 100 ], [ 98, 101 ], [ 98, 102 ], [ 102, 103 ], [ 103, 104 ], [ 102, 105 ], [ 102, 106 ], [ 55, 107 ], [ 107, 108 ], [ 108, 109 ], [ 107, 110 ], [ 53, 111 ], [ 111, 112 ], [ 53, 113 ], [ 113, 114 ], [ 53, 115 ], [ 115, 116 ], [ 0, 117 ], [ 117, 118 ], [ 117, 119 ] ]
[ "import java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.PrintWriter;\nimport java.util.Scanner;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n *\n * @author Mehvix\n */\npublic class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class abc167_b {\n public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }\n\n }\n}\n", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class abc167_b {\n public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }\n\n }\n}", "Main", "public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "Scanner in = new Scanner(inputStream);", "in", "new Scanner(inputStream)", "PrintWriter out = new PrintWriter(outputStream);", "out", "new PrintWriter(outputStream)", "abc167_b solver = new abc167_b();", "solver", "new abc167_b()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class abc167_b {\n public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }\n\n }", "abc167_b", "public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }", "solve", "{\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }", "int a = fin.nextInt();", "a", "fin.nextInt()", "fin.nextInt", "fin", "int b = fin.nextInt();", "b", "fin.nextInt()", "fin.nextInt", "fin", "int c = fin.nextInt();", "c", "fin.nextInt()", "fin.nextInt", "fin", "int k = fin.nextInt();", "k", "fin.nextInt()", "fin.nextInt", "fin", "int sum = 0;", "sum", "0", "sum += Math.min(a, Math.max(k, 0))", "sum", "Math.min(a, Math.max(k, 0))", "Math.min", "Math", "a", "Math.max(k, 0)", "Math.max", "Math", "k", "0", "k -= a", "k", "a", "k -= b", "k", "b", "sum -= Math.min(c, Math.max(k, 0))", "sum", "Math.min(c, Math.max(k, 0))", "Math.min", "Math", "c", "Math.max(k, 0)", "Math.max", "Math", "k", "0", "fout.println(sum)", "fout.println", "fout", "sum", "int testNumber", "testNumber", "Scanner fin", "fin", "PrintWriter fout", "fout", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class abc167_b {\n public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }\n\n }\n}", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n Scanner in = new Scanner(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n abc167_b solver = new abc167_b();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class abc167_b {\n public void solve(int testNumber, Scanner fin, PrintWriter fout) {\n int a = fin.nextInt();\n int b = fin.nextInt();\n int c = fin.nextInt();\n int k = fin.nextInt();\n\n int sum = 0;\n\n sum += Math.min(a, Math.max(k, 0));\n k -= a;\n k -= b;\n sum -= Math.min(c, Math.max(k, 0));\n\n fout.println(sum);\n }\n\n }\n}", "Main" ]
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.PrintWriter; import java.util.Scanner; /** * Built using CHelper plug-in * Actual solution is at the top * * @author Mehvix */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; Scanner in = new Scanner(inputStream); PrintWriter out = new PrintWriter(outputStream); abc167_b solver = new abc167_b(); solver.solve(1, in, out); out.close(); } static class abc167_b { public void solve(int testNumber, Scanner fin, PrintWriter fout) { int a = fin.nextInt(); int b = fin.nextInt(); int c = fin.nextInt(); int k = fin.nextInt(); int sum = 0; sum += Math.min(a, Math.max(k, 0)); k -= a; k -= b; sum -= Math.min(c, Math.max(k, 0)); fout.println(sum); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 13, 17, 0, 13, 13, 14, 2, 2, 13, 13, 2, 13, 17, 30, 0, 13, 2, 13, 17, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 13, 17, 0, 13, 13, 14, 2, 2, 13, 13, 2, 13, 17, 30, 0, 13, 2, 13, 40, 17, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 13, 40, 17, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 130, 5 ], [ 130, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 43, 45 ], [ 35, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 53, 54 ], [ 53, 55 ], [ 50, 56 ], [ 56, 57 ], [ 56, 58 ], [ 8, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 64, 65 ], [ 64, 66 ], [ 59, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 70, 72 ], [ 67, 73 ], [ 73, 74 ], [ 73, 75 ], [ 59, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 76, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 80, 86 ], [ 86, 87 ], [ 86, 88 ], [ 8, 89 ], [ 89, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 90, 94 ], [ 94, 95 ], [ 94, 96 ], [ 89, 97 ], [ 97, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 100, 102 ], [ 102, 103 ], [ 97, 104 ], [ 104, 105 ], [ 104, 106 ], [ 89, 107 ], [ 107, 108 ], [ 108, 109 ], [ 108, 110 ], [ 107, 111 ], [ 111, 112 ], [ 112, 113 ], [ 112, 114 ], [ 114, 115 ], [ 114, 116 ], [ 116, 117 ], [ 111, 118 ], [ 118, 119 ], [ 118, 120 ], [ 8, 121 ], [ 121, 122 ], [ 122, 123 ], [ 123, 124 ], [ 123, 125 ], [ 121, 126 ], [ 6, 127 ], [ 127, 128 ], [ 0, 129 ], [ 129, 130 ], [ 129, 131 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int sum = 0;", "sum", "0", "if(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}", "A>=K", "A", "K", "{\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}", "sum += K", "sum", "K", "K=0", "K", "0", "if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}", "A<K", "A", "K", "{\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}", "sum += A*1", "sum", "A*1", "A", "1", "K -= A", "K", "A", "if(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}", "B>=K && K != 0", "B>=K", "B", "K", "K != 0", "K", "0", "{\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}", "sum += K*0", "sum", "K*0", "K", "0", "K = 0", "K", "0", "if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}", "B<K", "B", "K", "{\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}", "sum += B*0", "sum", "B*0", "B", "0", "K -= B", "K", "B", "if(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}", "C>=K && K != 0", "C>=K", "C", "K", "K != 0", "K", "0", "{\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}", "sum += K*-1", "sum", "K*-1", "K", "-1", "1", "K = 0", "K", "0", "if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}", "C<K", "C", "K", "{\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}", "sum += C*-1", "sum", "C*-1", "C", "-1", "1", "K -= C", "K", "C", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tint sum = 0;\n\n\t\tif(A>=K) {\n\t\t\tsum += K;\n\t\t\tK=0;\n\t\t}\n\t\telse if(A<K) {\n\t\t\tsum += A*1;\n\t\t\tK -= A;\n\t\t}\n\n\t\tif(B>=K && K != 0) {\n\t\t\tsum += K*0;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(B<K) {\n\t\t\tsum += B*0;\n\t\t\tK -= B;\n\t\t}\n\n\t\tif(C>=K && K != 0) {\n\t\t\tsum += K*-1;\n\t\t\tK = 0;\n\t\t}\n\t\telse if(C<K) {\n\t\t\tsum += C*-1;\n\t\t\tK -= C;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int sum = 0; if(A>=K) { sum += K; K=0; } else if(A<K) { sum += A*1; K -= A; } if(B>=K && K != 0) { sum += K*0; K = 0; } else if(B<K) { sum += B*0; K -= B; } if(C>=K && K != 0) { sum += K*-1; K = 0; } else if(C<K) { sum += C*-1; K -= C; } System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 40, 13, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 13, 29, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 13, 29, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 40, 13, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 13, 29, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 129, 5 ], [ 129, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 35, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 35, 46 ], [ 47, 47 ], [ 47, 48 ], [ 48, 49 ], [ 47, 50 ], [ 50, 51 ], [ 47, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 52, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 57, 62 ], [ 56, 63 ], [ 8, 64 ], [ 64, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 64, 69 ], [ 69, 70 ], [ 69, 71 ], [ 64, 72 ], [ 72, 73 ], [ 73, 74 ], [ 64, 75 ], [ 76, 76 ], [ 76, 77 ], [ 77, 78 ], [ 76, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 79, 83 ], [ 83, 84 ], [ 84, 85 ], [ 85, 86 ], [ 86, 87 ], [ 86, 88 ], [ 84, 89 ], [ 83, 90 ], [ 8, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 91, 96 ], [ 96, 97 ], [ 96, 98 ], [ 91, 99 ], [ 99, 100 ], [ 100, 101 ], [ 91, 102 ], [ 103, 103 ], [ 103, 104 ], [ 104, 105 ], [ 103, 106 ], [ 106, 107 ], [ 103, 108 ], [ 108, 109 ], [ 109, 110 ], [ 109, 111 ], [ 108, 112 ], [ 112, 113 ], [ 113, 114 ], [ 114, 115 ], [ 115, 116 ], [ 115, 117 ], [ 113, 118 ], [ 112, 119 ], [ 8, 120 ], [ 120, 121 ], [ 121, 122 ], [ 122, 123 ], [ 122, 124 ], [ 120, 125 ], [ 6, 126 ], [ 126, 127 ], [ 0, 128 ], [ 128, 129 ], [ 128, 130 ] ]
[ "\nimport java.util.*;\n\npublic class Main {\n\n public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\n public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }", "main", "{\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }", "Scanner scn = new Scanner(System.in);", "scn", "new Scanner(System.in)", "int a = scn.nextInt();", "a", "scn.nextInt()", "scn.nextInt", "scn", "int b = scn.nextInt();", "b", "scn.nextInt()", "scn.nextInt", "scn", "int c = scn.nextInt();", "c", "scn.nextInt()", "scn.nextInt", "scn", "int k = scn.nextInt();", "k", "scn.nextInt()", "scn.nextInt", "scn", "int ans = 0;", "ans", "0", "for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < a", "i", "a", "i++", "i++", "i", "{\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "{\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "ans++", "ans", "k--", "k", "if (k <= 0) {\n System.out.println(ans);\n return;\n }", "k <= 0", "k", "0", "{\n System.out.println(ans);\n return;\n }", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "return;", "for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < b", "i", "b", "i++", "i++", "i", "{\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "{\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "k--", "k", "if (k <= 0) {\n System.out.println(ans);\n return;\n }", "k <= 0", "k", "0", "{\n System.out.println(ans);\n return;\n }", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "return;", "for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < c", "i", "c", "i++", "i++", "i", "{\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "{\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }", "ans--", "ans", "k--", "k", "if (k <= 0) {\n System.out.println(ans);\n return;\n }", "k <= 0", "k", "0", "{\n System.out.println(ans);\n return;\n }", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "return;", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n int a = scn.nextInt();\n int b = scn.nextInt();\n int c = scn.nextInt();\n int k = scn.nextInt();\n int ans = 0;\n for (int i = 0; i < a; i++) {\n ans++;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n ans--;\n k--;\n if (k <= 0) {\n System.out.println(ans);\n return;\n }\n }\n System.out.println(ans);\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner scn = new Scanner(System.in); int a = scn.nextInt(); int b = scn.nextInt(); int c = scn.nextInt(); int k = scn.nextInt(); int ans = 0; for (int i = 0; i < a; i++) { ans++; k--; if (k <= 0) { System.out.println(ans); return; } } for (int i = 0; i < b; i++) { k--; if (k <= 0) { System.out.println(ans); return; } } for (int i = 0; i < c; i++) { ans--; k--; if (k <= 0) { System.out.println(ans); return; } } System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 2, 13, 13, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 11, 1, 41, 13, 2, 13, 13, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 83, 5 ], [ 83, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 35, 40 ], [ 40, 41 ], [ 41, 42 ], [ 41, 43 ], [ 40, 44 ], [ 44, 45 ], [ 44, 46 ], [ 35, 47 ], [ 47, 48 ], [ 48, 49 ], [ 35, 50 ], [ 51, 51 ], [ 51, 52 ], [ 52, 53 ], [ 8, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 54, 61 ], [ 61, 62 ], [ 61, 63 ], [ 54, 64 ], [ 64, 65 ], [ 65, 66 ], [ 54, 67 ], [ 68, 68 ], [ 68, 69 ], [ 69, 70 ], [ 8, 71 ], [ 71, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 71, 76 ], [ 8, 77 ], [ 77, 78 ], [ 78, 79 ], [ 6, 80 ], [ 80, 81 ], [ 0, 82 ], [ 82, 83 ], [ 82, 84 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int sum = 0;", "sum", "0", "for (int i = 0; i < A && i < K; i++) {\n sum++;\n }", "int i = 0;", "int i = 0;", "i", "0", "i < A && i < K", "i < A", "i", "A", "i < K", "i", "K", "i++", "i++", "i", "{\n sum++;\n }", "{\n sum++;\n }", "sum++", "sum", "for (int i = (A + B); i < K; i++) {\n sum--;\n }", "int i = (A + B);", "int i = (A + B);", "i", "(A + B)", "A", "B", "i < K", "i", "K", "i++", "i++", "i", "{\n sum--;\n }", "{\n sum--;\n }", "sum--", "sum", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "sc.close()", "sc.close", "sc", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n\n int sum = 0;\n\n for (int i = 0; i < A && i < K; i++) {\n sum++;\n }\n for (int i = (A + B); i < K; i++) {\n sum--;\n }\n System.out.println(sum);\n sc.close();\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int sum = 0; for (int i = 0; i < A && i < K; i++) { sum++; } for (int i = (A + B); i < K; i++) { sum--; } System.out.println(sum); sc.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 41, 13, 20, 12, 13, 30, 41, 13, 4, 13, 41, 13, 4, 13, 41, 13, 4, 13, 41, 13, 4, 13, 41, 13, 17, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 13, 17, 0, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 13, 17, 0, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 13, 17, 0, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 23, 13, 12, 13, 30, 29, 4, 18, 4, 13, 17, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 13, 23, 13, 12, 13, 30, 29, 4, 13, 13, 23, 13, 12, 13, 30, 29, 2, 4, 13, 13, 2, 4, 13, 13, 4, 13, 2, 13, 13, 23, 13, 23, 13, 12, 13, 30, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 13, 2, 13, 13, 29, 13, 23, 13, 12, 13, 30, 14, 2, 13, 17, 30, 29, 13, 30, 0, 13, 2, 13, 13, 29, 4, 13, 13, 13, 23, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 347, 11 ], [ 347, 12 ], [ 12, 13 ], [ 347, 14 ], [ 14, 15 ], [ 14, 16 ], [ 347, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 19, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 19, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 19, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 19, 36 ], [ 36, 37 ], [ 36, 38 ], [ 19, 39 ], [ 39, 40 ], [ 39, 41 ], [ 19, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 42, 47 ], [ 47, 48 ], [ 47, 49 ], [ 42, 50 ], [ 50, 51 ], [ 51, 52 ], [ 42, 53 ], [ 54, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 54, 58 ], [ 58, 59 ], [ 58, 60 ], [ 54, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 66, 71 ], [ 65, 72 ], [ 19, 73 ], [ 73, 74 ], [ 74, 75 ], [ 75, 76 ], [ 75, 77 ], [ 73, 78 ], [ 78, 79 ], [ 78, 80 ], [ 73, 81 ], [ 81, 82 ], [ 82, 83 ], [ 73, 84 ], [ 85, 85 ], [ 85, 86 ], [ 86, 87 ], [ 86, 88 ], [ 85, 89 ], [ 89, 90 ], [ 89, 91 ], [ 85, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 92, 96 ], [ 96, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 97, 102 ], [ 96, 103 ], [ 19, 104 ], [ 104, 105 ], [ 105, 106 ], [ 106, 107 ], [ 106, 108 ], [ 104, 109 ], [ 109, 110 ], [ 109, 111 ], [ 104, 112 ], [ 112, 113 ], [ 113, 114 ], [ 104, 115 ], [ 116, 116 ], [ 116, 117 ], [ 117, 118 ], [ 117, 119 ], [ 116, 120 ], [ 120, 121 ], [ 120, 122 ], [ 116, 123 ], [ 123, 124 ], [ 124, 125 ], [ 124, 126 ], [ 123, 127 ], [ 127, 128 ], [ 128, 129 ], [ 129, 130 ], [ 130, 131 ], [ 130, 132 ], [ 128, 133 ], [ 127, 134 ], [ 17, 135 ], [ 135, 136 ], [ 347, 137 ], [ 137, 138 ], [ 137, 139 ], [ 139, 140 ], [ 140, 141 ], [ 141, 142 ], [ 142, 143 ], [ 143, 144 ], [ 141, 145 ], [ 347, 146 ], [ 146, 147 ], [ 146, 148 ], [ 148, 149 ], [ 149, 150 ], [ 150, 151 ], [ 151, 152 ], [ 150, 153 ], [ 153, 154 ], [ 347, 155 ], [ 155, 156 ], [ 155, 157 ], [ 157, 158 ], [ 158, 159 ], [ 159, 160 ], [ 160, 161 ], [ 159, 162 ], [ 162, 163 ], [ 347, 164 ], [ 164, 165 ], [ 164, 166 ], [ 166, 167 ], [ 167, 168 ], [ 168, 169 ], [ 169, 170 ], [ 168, 171 ], [ 171, 172 ], [ 347, 173 ], [ 173, 174 ], [ 173, 175 ], [ 175, 176 ], [ 176, 177 ], [ 176, 178 ], [ 175, 180 ], [ 180, 181 ], [ 181, 182 ], [ 182, 183 ], [ 182, 184 ], [ 180, 185 ], [ 185, 186 ], [ 185, 187 ], [ 180, 188 ], [ 188, 189 ], [ 189, 190 ], [ 180, 191 ], [ 192, 192 ], [ 192, 193 ], [ 193, 194 ], [ 194, 195 ], [ 194, 196 ], [ 193, 197 ], [ 197, 198 ], [ 175, 199 ], [ 199, 200 ], [ 173, 201 ], [ 201, 202 ], [ 347, 203 ], [ 203, 204 ], [ 203, 205 ], [ 205, 206 ], [ 206, 207 ], [ 206, 208 ], [ 205, 210 ], [ 210, 211 ], [ 211, 212 ], [ 212, 213 ], [ 212, 214 ], [ 210, 215 ], [ 215, 216 ], [ 215, 217 ], [ 210, 218 ], [ 218, 219 ], [ 219, 220 ], [ 210, 221 ], [ 222, 222 ], [ 222, 223 ], [ 223, 224 ], [ 224, 225 ], [ 224, 226 ], [ 223, 227 ], [ 227, 228 ], [ 205, 229 ], [ 229, 230 ], [ 203, 231 ], [ 231, 232 ], [ 347, 233 ], [ 233, 234 ], [ 233, 235 ], [ 235, 236 ], [ 236, 237 ], [ 237, 238 ], [ 238, 239 ], [ 238, 240 ], [ 237, 241 ], [ 241, 242 ], [ 242, 243 ], [ 243, 244 ], [ 236, 245 ], [ 245, 246 ], [ 246, 247 ], [ 246, 248 ], [ 235, 249 ], [ 249, 250 ], [ 250, 251 ], [ 251, 252 ], [ 347, 253 ], [ 253, 254 ], [ 253, 255 ], [ 255, 256 ], [ 256, 257 ], [ 257, 258 ], [ 258, 259 ], [ 257, 260 ], [ 253, 261 ], [ 261, 262 ], [ 347, 263 ], [ 263, 264 ], [ 263, 265 ], [ 265, 266 ], [ 266, 267 ], [ 267, 268 ], [ 267, 269 ], [ 263, 270 ], [ 270, 271 ], [ 347, 272 ], [ 272, 273 ], [ 272, 274 ], [ 274, 275 ], [ 275, 276 ], [ 276, 277 ], [ 277, 278 ], [ 277, 279 ], [ 276, 280 ], [ 280, 281 ], [ 281, 282 ], [ 281, 283 ], [ 280, 284 ], [ 284, 285 ], [ 284, 286 ], [ 286, 287 ], [ 286, 288 ], [ 272, 289 ], [ 289, 290 ], [ 272, 291 ], [ 291, 292 ], [ 347, 293 ], [ 293, 294 ], [ 293, 295 ], [ 295, 296 ], [ 296, 297 ], [ 296, 298 ], [ 295, 299 ], [ 299, 300 ], [ 300, 301 ], [ 301, 302 ], [ 301, 303 ], [ 299, 304 ], [ 304, 305 ], [ 304, 306 ], [ 299, 307 ], [ 307, 308 ], [ 308, 309 ], [ 299, 310 ], [ 311, 311 ], [ 311, 312 ], [ 312, 313 ], [ 312, 314 ], [ 314, 315 ], [ 314, 316 ], [ 295, 317 ], [ 317, 318 ], [ 293, 319 ], [ 319, 320 ], [ 347, 321 ], [ 321, 322 ], [ 321, 323 ], [ 323, 324 ], [ 324, 325 ], [ 325, 326 ], [ 325, 327 ], [ 324, 328 ], [ 328, 329 ], [ 329, 330 ], [ 324, 331 ], [ 331, 332 ], [ 332, 333 ], [ 332, 334 ], [ 334, 335 ], [ 334, 336 ], [ 331, 337 ], [ 337, 338 ], [ 338, 339 ], [ 338, 340 ], [ 338, 341 ], [ 321, 342 ], [ 342, 343 ], [ 321, 344 ], [ 344, 345 ], [ 0, 346 ], [ 346, 347 ], [ 346, 348 ] ]
[ "import java.util.*;\nimport java.io.*;\nimport static java.lang.Math.*;\n\npublic class Main {\n static StringTokenizer st;\n static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n public static void main(String[] args) throws IOException {\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }\n\n static char nextChar() throws IOException {\n return next().charAt(0);\n }\n\n static int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n static long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n static double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n static int[] readArray(int n) throws IOException {\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }\n\n static long[] readLongArray(int n) throws IOException {\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }\n\n static String next() throws IOException {\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }\n\n static int Char2Int(Character c) {\n return Character.getNumericValue(c);\n }\n\n static double Char2Double(Character c) {\n return (double) Char2Int(c);\n }\n\n static int nCr(int n, int r) {\n return fact(n) / (fact(r) * fact(n - r));\n }\n\n // Returns factorial of n\n static int fact(int n) {\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }\n\n static int gcd(int a, int b) {\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }\n}", "import java.util.*;", "util.*", "java", "import java.io.*;", "io.*", "java", "import static java.lang.Math.*;", "import static java.lang.Math.*;", "import static java.lang.Math.*;", "public class Main {\n static StringTokenizer st;\n static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n public static void main(String[] args) throws IOException {\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }\n\n static char nextChar() throws IOException {\n return next().charAt(0);\n }\n\n static int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n static long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n static double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n static int[] readArray(int n) throws IOException {\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }\n\n static long[] readLongArray(int n) throws IOException {\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }\n\n static String next() throws IOException {\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }\n\n static int Char2Int(Character c) {\n return Character.getNumericValue(c);\n }\n\n static double Char2Double(Character c) {\n return (double) Char2Int(c);\n }\n\n static int nCr(int n, int r) {\n return fact(n) / (fact(r) * fact(n - r));\n }\n\n // Returns factorial of n\n static int fact(int n) {\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }\n\n static int gcd(int a, int b) {\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }\n}", "Main", "static StringTokenizer st;", "st", "static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "public static void main(String[] args) throws IOException {\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }", "main", "{\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }", "int a = nextInt();", "a", "nextInt()", "nextInt", "int b = nextInt();", "b", "nextInt()", "nextInt", "int c = nextInt();", "c", "nextInt()", "nextInt", "int k = nextInt();", "k", "nextInt()", "nextInt", "int result = 0;", "result", "0", "int sum = 0;", "sum", "0", "for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < a", "i", "a", "i++", "i++", "i", "{\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "{\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "result += 1", "result", "1", "sum += 1", "sum", "1", "if (sum == k) {\n System.out.println(result);\n return;\n }", "sum == k", "sum", "k", "{\n System.out.println(result);\n return;\n }", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "return;", "for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < b", "i", "b", "i++", "i++", "i", "{\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "{\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "result += 0", "result", "0", "sum += 1", "sum", "1", "if (sum == k) {\n System.out.println(result);\n return;\n }", "sum == k", "sum", "k", "{\n System.out.println(result);\n return;\n }", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "return;", "for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "int i = 0;", "int i = 0;", "i", "0", "i < c", "i", "c", "i++", "i++", "i", "{\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "{\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }", "result -= 1", "result", "1", "sum += 1", "sum", "1", "if (sum == k) {\n System.out.println(result);\n return;\n }", "sum == k", "sum", "k", "{\n System.out.println(result);\n return;\n }", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "return;", "String[] args", "args", "static char nextChar() throws IOException {\n return next().charAt(0);\n }", "nextChar", "{\n return next().charAt(0);\n }", "return next().charAt(0);", "next().charAt(0)", "next().charAt", "next()", "next", "0", "static int nextInt() throws IOException {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "static long nextLong() throws IOException {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "static double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "static int[] readArray(int n) throws IOException {\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }", "readArray", "{\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }", "int[] a = new int[n];", "a", "new int[n]", "n", "for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n a[i] = nextInt();\n }", "{\n a[i] = nextInt();\n }", "a[i] = nextInt()", "a[i]", "a", "i", "nextInt()", "nextInt", "return a;", "a", "int n", "n", "static long[] readLongArray(int n) throws IOException {\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }", "readLongArray", "{\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }", "long[] a = new long[n];", "a", "new long[n]", "n", "for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }", "int i = 0;", "int i = 0;", "i", "0", "i < n", "i", "n", "i++", "i++", "i", "{\n a[i] = nextLong();\n }", "{\n a[i] = nextLong();\n }", "a[i] = nextLong()", "a[i]", "a", "i", "nextLong()", "nextLong", "return a;", "a", "int n", "n", "static String next() throws IOException {\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }", "while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }", "st == null || !st.hasMoreTokens()", "st == null", "st", "null", "!st.hasMoreTokens()", "st.hasMoreTokens()", "st.hasMoreTokens", "st", "{\n st = new StringTokenizer(br.readLine().trim());\n }", "st = new StringTokenizer(br.readLine().trim())", "st", "new StringTokenizer(br.readLine().trim())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "static int Char2Int(Character c) {\n return Character.getNumericValue(c);\n }", "Char2Int", "{\n return Character.getNumericValue(c);\n }", "return Character.getNumericValue(c);", "Character.getNumericValue(c)", "Character.getNumericValue", "Character", "c", "Character c", "c", "static double Char2Double(Character c) {\n return (double) Char2Int(c);\n }", "Char2Double", "{\n return (double) Char2Int(c);\n }", "return (double) Char2Int(c);", "(double) Char2Int(c)", "Char2Int", "c", "Character c", "c", "static int nCr(int n, int r) {\n return fact(n) / (fact(r) * fact(n - r));\n }", "nCr", "{\n return fact(n) / (fact(r) * fact(n - r));\n }", "return fact(n) / (fact(r) * fact(n - r));", "fact(n) / (fact(r) * fact(n - r))", "fact(n)", "fact", "n", "(fact(r) * fact(n - r))", "fact(r)", "fact", "r", "fact(n - r)", "fact", "n - r", "n", "r", "int n", "n", "int r", "r", "// Returns factorial of n\n static int fact(int n) {\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }", "fact", "{\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }", "int res = 1;", "res", "1", "for (int i = 2; i <= n; i++) {\n res = res * i;\n }", "int i = 2;", "int i = 2;", "i", "2", "i <= n", "i", "n", "i++", "i++", "i", "{\n res = res * i;\n }", "{\n res = res * i;\n }", "res = res * i", "res", "res * i", "res", "i", "return res;", "res", "int n", "n", "static int gcd(int a, int b) {\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }", "gcd", "{\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }", "if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }", "b == 0", "b", "0", "{\n return a;\n }", "return a;", "a", "{\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }", "a = a % b", "a", "a % b", "a", "b", "return gcd(b, a); // 残り部分から最小の正方形を見つける", "gcd(b, a)", "gcd", "b", "a", "int a", "a", "int b", "b", "public class Main {\n static StringTokenizer st;\n static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n public static void main(String[] args) throws IOException {\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }\n\n static char nextChar() throws IOException {\n return next().charAt(0);\n }\n\n static int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n static long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n static double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n static int[] readArray(int n) throws IOException {\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }\n\n static long[] readLongArray(int n) throws IOException {\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }\n\n static String next() throws IOException {\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }\n\n static int Char2Int(Character c) {\n return Character.getNumericValue(c);\n }\n\n static double Char2Double(Character c) {\n return (double) Char2Int(c);\n }\n\n static int nCr(int n, int r) {\n return fact(n) / (fact(r) * fact(n - r));\n }\n\n // Returns factorial of n\n static int fact(int n) {\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }\n\n static int gcd(int a, int b) {\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }\n}", "public class Main {\n static StringTokenizer st;\n static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n public static void main(String[] args) throws IOException {\n int a = nextInt();\n int b = nextInt();\n int c = nextInt();\n int k = nextInt();\n\n int result = 0;\n int sum = 0;\n for (int i = 0; i < a; i++) {\n result += 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < b; i++) {\n result += 0;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n for (int i = 0; i < c; i++) {\n result -= 1;\n sum += 1;\n if (sum == k) {\n System.out.println(result);\n return;\n }\n }\n\n }\n\n static char nextChar() throws IOException {\n return next().charAt(0);\n }\n\n static int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n static long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n static double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n static int[] readArray(int n) throws IOException {\n int[] a = new int[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextInt();\n }\n return a;\n }\n\n static long[] readLongArray(int n) throws IOException {\n long[] a = new long[n];\n for (int i = 0; i < n; i++) {\n a[i] = nextLong();\n }\n return a;\n }\n\n static String next() throws IOException {\n while (st == null || !st.hasMoreTokens()) {\n st = new StringTokenizer(br.readLine().trim());\n }\n return st.nextToken();\n }\n\n static int Char2Int(Character c) {\n return Character.getNumericValue(c);\n }\n\n static double Char2Double(Character c) {\n return (double) Char2Int(c);\n }\n\n static int nCr(int n, int r) {\n return fact(n) / (fact(r) * fact(n - r));\n }\n\n // Returns factorial of n\n static int fact(int n) {\n int res = 1;\n for (int i = 2; i <= n; i++) {\n res = res * i;\n }\n return res;\n }\n\n static int gcd(int a, int b) {\n if (b == 0) {\n return a;\n } else {\n a = a % b; // 残り部分\n return gcd(b, a); // 残り部分から最小の正方形を見つける\n }\n }\n}", "Main" ]
import java.util.*; import java.io.*; import static java.lang.Math.*; public class Main { static StringTokenizer st; static BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); public static void main(String[] args) throws IOException { int a = nextInt(); int b = nextInt(); int c = nextInt(); int k = nextInt(); int result = 0; int sum = 0; for (int i = 0; i < a; i++) { result += 1; sum += 1; if (sum == k) { System.out.println(result); return; } } for (int i = 0; i < b; i++) { result += 0; sum += 1; if (sum == k) { System.out.println(result); return; } } for (int i = 0; i < c; i++) { result -= 1; sum += 1; if (sum == k) { System.out.println(result); return; } } } static char nextChar() throws IOException { return next().charAt(0); } static int nextInt() throws IOException { return Integer.parseInt(next()); } static long nextLong() throws IOException { return Long.parseLong(next()); } static double nextDouble() throws IOException { return Double.parseDouble(next()); } static int[] readArray(int n) throws IOException { int[] a = new int[n]; for (int i = 0; i < n; i++) { a[i] = nextInt(); } return a; } static long[] readLongArray(int n) throws IOException { long[] a = new long[n]; for (int i = 0; i < n; i++) { a[i] = nextLong(); } return a; } static String next() throws IOException { while (st == null || !st.hasMoreTokens()) { st = new StringTokenizer(br.readLine().trim()); } return st.nextToken(); } static int Char2Int(Character c) { return Character.getNumericValue(c); } static double Char2Double(Character c) { return (double) Char2Int(c); } static int nCr(int n, int r) { return fact(n) / (fact(r) * fact(n - r)); } // Returns factorial of n static int fact(int n) { int res = 1; for (int i = 2; i <= n; i++) { res = res * i; } return res; } static int gcd(int a, int b) { if (b == 0) { return a; } else { a = a % b; // 残り部分 return gcd(b, a); // 残り部分から最小の正方形を見つける } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 4, 18, 13, 13, 13, 41, 13, 17, 41, 13, 17, 14, 2, 2, 13, 13, 17, 30, 0, 13, 4, 18, 13, 13, 2, 13, 13, 14, 2, 2, 2, 13, 13, 13, 17, 30, 0, 13, 2, 2, 13, 13, 13, 0, 13, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 105, 5 ], [ 105, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 37, 40 ], [ 37, 41 ], [ 8, 42 ], [ 42, 43 ], [ 42, 44 ], [ 8, 45 ], [ 45, 46 ], [ 45, 47 ], [ 8, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 49, 53 ], [ 48, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 58, 59 ], [ 57, 60 ], [ 57, 61 ], [ 61, 62 ], [ 61, 63 ], [ 54, 64 ], [ 64, 65 ], [ 65, 66 ], [ 67, 67 ], [ 67, 68 ], [ 67, 69 ], [ 67, 70 ], [ 65, 71 ], [ 64, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 76, 76 ], [ 76, 77 ], [ 76, 78 ], [ 76, 79 ], [ 8, 80 ], [ 80, 81 ], [ 80, 82 ], [ 82, 83 ], [ 83, 84 ], [ 84, 85 ], [ 84, 86 ], [ 83, 87 ], [ 87, 88 ], [ 87, 89 ], [ 82, 90 ], [ 90, 91 ], [ 90, 92 ], [ 8, 93 ], [ 93, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 93, 98 ], [ 8, 99 ], [ 99, 100 ], [ 100, 101 ], [ 6, 102 ], [ 102, 103 ], [ 0, 104 ], [ 104, 105 ], [ 104, 106 ] ]
[ "\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}", "main", "{\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int A = scan.nextInt();", "A", "scan.nextInt()", "scan.nextInt", "scan", "int B = scan.nextInt();", "B", "scan.nextInt()", "scan.nextInt", "scan", "int C = scan.nextInt();", "C", "scan.nextInt()", "scan.nextInt", "scan", "int K = scan.nextInt();", "K", "scan.nextInt()", "scan.nextInt", "scan", "int ans = 0;", "ans", "0", "int point1 = Math.min(A, K);", "point1", "Math.min(A, K)", "Math.min", "Math", "A", "K", "int point0 = 0;", "point0", "0", "int pointMinus1 = 0;", "pointMinus1", "0", "if(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}", "K - point1 > 0", "K - point1", "K", "point1", "0", "{\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}", "point0 = Math.min(B, K-point1)", "point0", "Math.min(B, K-point1)", "Math.min", "Math", "B", "K-point1", "K", "point1", "if(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}", "K - point1 - point0 > 0", "K - point1 - point0", "K - point1 - point0", "K", "point1", "point0", "0", "{\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}", "pointMinus1 = K - point1 - point0", "pointMinus1", "K - point1 - point0", "K - point1 - point0", "K", "point1", "point0", "ans = point1 * 1 + point0 * 0 - pointMinus1 * 1", "ans", "point1 * 1 + point0 * 0 - pointMinus1 * 1", "point1 * 1 + point0 * 0", "point1 * 1", "point1", "1", "point0 * 0", "point0", "0", "pointMinus1 * 1", "pointMinus1", "1", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "scan.close()", "scan.close", "scan", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\t\tint ans = 0;\n\n\t\tint point1 = Math.min(A, K);\n\t\tint point0 = 0;\n\t\tint pointMinus1 = 0;\n\n\n\t\tif(K - point1 > 0) {\n\t\t\tpoint0 = Math.min(B, K-point1);\n\n\t\t\tif(K - point1 - point0 > 0) {\n\t\t\t\tpointMinus1 = K - point1 - point0;\n\t\t\t}\n\n\t\t}\n\n\t\tans = point1 * 1 + point0 * 0 - pointMinus1 * 1;\n\n\t\tSystem.out.println(ans);\n\t\tscan.close();\n\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int A = scan.nextInt(); int B = scan.nextInt(); int C = scan.nextInt(); int K = scan.nextInt(); int ans = 0; int point1 = Math.min(A, K); int point0 = 0; int pointMinus1 = 0; if(K - point1 > 0) { point0 = Math.min(B, K-point1); if(K - point1 - point0 > 0) { pointMinus1 = K - point1 - point0; } } ans = point1 * 1 + point0 * 0 - pointMinus1 * 1; System.out.println(ans); scan.close(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 41, 13, 2, 2, 2, 13, 17, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 75, 5 ], [ 75, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 32, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 50, 55 ], [ 43, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 59, 65 ], [ 56, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 66, 71 ], [ 6, 72 ], [ 72, 73 ], [ 0, 74 ], [ 74, 75 ], [ 74, 76 ] ]
[ "import java.util.*;\npublic class Main{\n public static void main(String[] args){\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }\n}", "import java.util.*;", "util.*", "java", "public class Main{\n public static void main(String[] args){\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }\n}", "Main", "public static void main(String[] args){\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }", "main", "{\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }", "Scanner sc =new Scanner(System.in);", "sc", "new Scanner(System.in)", "long A =sc.nextLong();", "A", "sc.nextLong()", "sc.nextLong", "sc", "long B =sc.nextLong();", "B", "sc.nextLong()", "sc.nextLong", "sc", "long C =sc.nextLong();", "C", "sc.nextLong()", "sc.nextLong", "sc", "long K =sc.nextLong();", "K", "sc.nextLong()", "sc.nextLong", "sc", "if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}", "K<A", "K", "A", "{System.out.println(K);}", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}", "K<A+B", "K", "A+B", "A", "B", "{System.out.println(A);}", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "{long D =A*2+B-K;\n System.out.println(D);}", "long D =A*2+B-K;", "D", "A*2+B-K", "A*2+B", "A*2", "A", "2", "B", "K", "System.out.println(D)", "System.out.println", "System.out", "System", "System.out", "D", "String[] args", "args", "public class Main{\n public static void main(String[] args){\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }\n}", "public class Main{\n public static void main(String[] args){\n Scanner sc =new Scanner(System.in);\n long A =sc.nextLong();\n long B =sc.nextLong();\n long C =sc.nextLong();\n long K =sc.nextLong();\n if(K<A){System.out.println(K);}\n else if(K<A+B){System.out.println(A);}\n else{long D =A*2+B-K;\n System.out.println(D);}\n }\n}", "Main" ]
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc =new Scanner(System.in); long A =sc.nextLong(); long B =sc.nextLong(); long C =sc.nextLong(); long K =sc.nextLong(); if(K<A){System.out.println(K);} else if(K<A+B){System.out.println(A);} else{long D =A*2+B-K; System.out.println(D);} } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 2, 13, 13, 13, 30, 0, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 83, 5 ], [ 83, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 43, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 57, 57 ], [ 57, 58 ], [ 57, 59 ], [ 57, 60 ], [ 53, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 64, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 8, 71 ], [ 71, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 71, 76 ], [ 8, 77 ], [ 77, 78 ], [ 78, 79 ], [ 6, 80 ], [ 80, 81 ], [ 0, 82 ], [ 82, 83 ], [ 82, 84 ] ]
[ "import java.util.Scanner;\n\n/**\n * B - Easy Linear Programming\n * 1 が書かれたカードが A 枚、0 が書かれたカードが B 枚、−1 が書かれたカードが C 枚あります。\n * これらのカードから、ちょうど K 枚を選んで取るとき、取ったカードに書かれた数の和として、 ありうる値の最大値はいくつですか。\n */\npublic class Main {\n\n public static void main(String[] args) {\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }\n}", "Main", "public static void main(String[] args) {\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }", "main", "{\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }", "Scanner sc = new Scanner( System.in );", "sc", "new Scanner( System.in )", "long a = sc.nextLong();", "a", "sc.nextLong()", "sc.nextLong", "sc", "long b = sc.nextLong();", "b", "sc.nextLong()", "sc.nextLong", "sc", "long c = sc.nextLong();", "c", "sc.nextLong()", "sc.nextLong", "sc", "long k = sc.nextLong();", "k", "sc.nextLong()", "sc.nextLong", "sc", "long result = 0;", "result", "0", "if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }", "k <= a", "k", "a", "{\n result = k;\n }", "result = k", "result", "k", "if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }", "k <= a + b", "k", "a + b", "a", "b", "{\n result = a;\n }", "result = a", "result", "a", "if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }", "k <= a + b + c", "k", "a + b + c", "a + b + c", "a", "b", "c", "{\n result = a - ( k - a - b );\n }", "result = a - ( k - a - b )", "result", "a - ( k - a - b )", "a", "( k - a - b )", "k - a - b", "k", "a", "b", "System.out.println( result )", "System.out.println", "System.out", "System", "System.out", "result", "sc.close()", "sc.close", "sc", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n\n Scanner sc = new Scanner( System.in );\n long a = sc.nextLong();\n long b = sc.nextLong();\n long c = sc.nextLong();\n long k = sc.nextLong();\n\n long result = 0;\n\n\n if( k <= a ) {\n result = k;\n }\n else if( k <= a + b ) {\n result = a;\n }\n else if( k <= a + b + c ) {\n result = a - ( k - a - b );\n }\n\n System.out.println( result );\n\n sc.close();\n }\n}", "Main" ]
import java.util.Scanner; /** * B - Easy Linear Programming * 1 が書かれたカードが A 枚、0 が書かれたカードが B 枚、−1 が書かれたカードが C 枚あります。 * これらのカードから、ちょうど K 枚を選んで取るとき、取ったカードに書かれた数の和として、 ありうる値の最大値はいくつですか。 */ public class Main { public static void main(String[] args) { Scanner sc = new Scanner( System.in ); long a = sc.nextLong(); long b = sc.nextLong(); long c = sc.nextLong(); long k = sc.nextLong(); long result = 0; if( k <= a ) { result = k; } else if( k <= a + b ) { result = a; } else if( k <= a + b + c ) { result = a - ( k - a - b ); } System.out.println( result ); sc.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 41, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 13, 2, 13, 17, 13, 0, 13, 4, 18, 13, 13, 13, 41, 13, 2, 18, 13, 13, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 2, 18, 13, 2, 2, 13, 13, 17, 2, 13, 17, 2, 18, 13, 2, 2, 13, 13, 17, 18, 13, 2, 13, 17, 30, 4, 13, 2, 13, 13, 2, 13, 17, 23, 13, 23, 13, 12, 13, 30, 42, 2, 2, 2, 13, 13, 17, 2, 2, 13, 13, 17, 30, 14, 2, 13, 13, 0, 13, 13, 0, 13, 13, 29, 8, 2, 13, 13, 13, 13, 23, 13, 23, 13, 12, 13, 30, 29, 8, 2, 2, 13, 13, 17, 2, 13, 13, 2, 2, 13, 13, 17, 23, 13, 23, 13, 12, 13, 30, 41, 13, 17, 42, 2, 13, 17, 30, 0, 13, 2, 13, 17, 0, 13, 17, 29, 13, 23, 13, 12, 13, 30, 42, 2, 40, 13, 17, 4, 18, 13, 2, 17, 17, 23, 13, 12, 13, 30, 11, 1, 41, 13, 17, 2, 13, 4, 18, 13, 1, 40, 13, 30, 14, 2, 4, 18, 13, 13, 17, 29, 17, 29, 17, 23, 13, 12, 13, 30, 41, 13, 20, 0, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 14, 2, 13, 2, 13, 13, 30, 4, 18, 13, 2, 13, 2, 2, 13, 13, 13, 30, 4, 18, 13, 13, 30, 4, 18, 13, 13, 4, 18, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 0, 18, 13, 13, 4, 13, 29, 13, 23, 13, 12, 13, 30, 29, 4, 18, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 23, 13, 23, 13, 12, 13, 30, 29, 4, 18, 2, 2, 18, 36, 13, 17, 18, 36, 13, 12, 13, 30, 14, 2, 18, 36, 13, 18, 13, 13, 29, 2, 18, 36, 13, 18, 13, 13, 30, 29, 2, 18, 36, 13, 18, 13, 13, 23, 13, 12, 13, 30, 14, 2, 13, 17, 30, 29, 17, 14, 2, 4, 18, 36, 4, 18, 13, 30, 29, 17, 41, 13, 13, 29, 2, 2, 18, 36, 13, 18, 13, 13, 2, 18, 36, 13, 18, 13, 13, 23, 13, 13, 6, 13, 41, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 23, 13, 23, 13, 23, 13, 12, 13, 30, 14, 2, 18, 36, 13, 18, 13, 13, 29, 2, 18, 36, 13, 18, 13, 13, 30, 14, 2, 18, 36, 13, 18, 13, 13, 29, 2, 18, 36, 13, 18, 13, 13, 29, 2, 18, 36, 13, 18, 13, 13, 23, 13, 12, 13, 30, 29, 2, 2, 18, 36, 13, 18, 13, 13, 2, 18, 36, 13, 18, 13, 13, 23, 13, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 23, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 664, 8 ], [ 664, 9 ], [ 9, 10 ], [ 664, 11 ], [ 11, 12 ], [ 664, 13 ], [ 13, 14 ], [ 664, 15 ], [ 15, 16 ], [ 664, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 21, 22 ], [ 21, 23 ], [ 23, 24 ], [ 23, 25 ], [ 20, 26 ], [ 19, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 29, 32 ], [ 29, 33 ], [ 19, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 36, 40 ], [ 19, 41 ], [ 41, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 41, 46 ], [ 46, 47 ], [ 46, 48 ], [ 41, 49 ], [ 49, 50 ], [ 50, 51 ], [ 41, 52 ], [ 53, 53 ], [ 53, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 59, 63 ], [ 56, 64 ], [ 64, 65 ], [ 64, 66 ], [ 55, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 67, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 77, 79 ], [ 54, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 81, 86 ], [ 86, 87 ], [ 86, 88 ], [ 17, 89 ], [ 89, 90 ], [ 17, 91 ], [ 91, 92 ], [ 664, 93 ], [ 93, 94 ], [ 93, 95 ], [ 95, 96 ], [ 96, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 98, 102 ], [ 97, 103 ], [ 103, 104 ], [ 104, 105 ], [ 104, 106 ], [ 103, 107 ], [ 96, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 110, 112 ], [ 109, 113 ], [ 113, 114 ], [ 113, 115 ], [ 109, 116 ], [ 116, 117 ], [ 116, 118 ], [ 95, 119 ], [ 119, 120 ], [ 120, 121 ], [ 121, 122 ], [ 121, 123 ], [ 120, 124 ], [ 120, 125 ], [ 93, 126 ], [ 126, 127 ], [ 93, 128 ], [ 128, 129 ], [ 664, 130 ], [ 130, 131 ], [ 130, 132 ], [ 132, 133 ], [ 133, 134 ], [ 134, 135 ], [ 135, 136 ], [ 136, 137 ], [ 136, 138 ], [ 135, 139 ], [ 134, 140 ], [ 140, 141 ], [ 140, 142 ], [ 134, 143 ], [ 143, 144 ], [ 144, 145 ], [ 144, 146 ], [ 143, 147 ], [ 130, 148 ], [ 148, 149 ], [ 130, 150 ], [ 150, 151 ], [ 664, 152 ], [ 152, 153 ], [ 152, 154 ], [ 154, 155 ], [ 155, 156 ], [ 155, 157 ], [ 154, 158 ], [ 158, 159 ], [ 159, 160 ], [ 159, 161 ], [ 158, 162 ], [ 162, 163 ], [ 163, 164 ], [ 163, 165 ], [ 165, 166 ], [ 165, 167 ], [ 162, 168 ], [ 168, 169 ], [ 168, 170 ], [ 154, 171 ], [ 171, 172 ], [ 152, 173 ], [ 173, 174 ], [ 664, 175 ], [ 175, 176 ], [ 175, 177 ], [ 177, 178 ], [ 178, 179 ], [ 179, 180 ], [ 180, 181 ], [ 179, 182 ], [ 178, 183 ], [ 183, 184 ], [ 184, 185 ], [ 183, 186 ], [ 186, 187 ], [ 186, 188 ], [ 175, 189 ], [ 189, 190 ], [ 664, 191 ], [ 191, 192 ], [ 191, 193 ], [ 193, 194 ], [ 194, 195 ], [ 195, 196 ], [ 196, 197 ], [ 196, 198 ], [ 194, 199 ], [ 199, 200 ], [ 199, 201 ], [ 201, 202 ], [ 202, 203 ], [ 194, 204 ], [ 204, 205 ], [ 205, 206 ], [ 194, 207 ], [ 207, 208 ], [ 208, 209 ], [ 209, 210 ], [ 210, 211 ], [ 211, 212 ], [ 210, 213 ], [ 209, 214 ], [ 208, 215 ], [ 215, 216 ], [ 193, 217 ], [ 217, 218 ], [ 191, 219 ], [ 219, 220 ], [ 664, 221 ], [ 221, 222 ], [ 221, 223 ], [ 223, 224 ], [ 224, 225 ], [ 224, 226 ], [ 223, 227 ], [ 227, 228 ], [ 227, 229 ], [ 223, 230 ], [ 230, 231 ], [ 230, 232 ], [ 232, 233 ], [ 233, 234 ], [ 223, 235 ], [ 235, 236 ], [ 235, 237 ], [ 237, 238 ], [ 238, 239 ], [ 223, 240 ], [ 240, 241 ], [ 240, 242 ], [ 242, 243 ], [ 243, 244 ], [ 223, 245 ], [ 245, 246 ], [ 245, 247 ], [ 247, 248 ], [ 248, 249 ], [ 223, 250 ], [ 250, 251 ], [ 251, 252 ], [ 251, 253 ], [ 250, 254 ], [ 254, 255 ], [ 255, 256 ], [ 256, 257 ], [ 256, 258 ], [ 258, 259 ], [ 258, 260 ], [ 255, 261 ], [ 261, 262 ], [ 262, 263 ], [ 263, 264 ], [ 262, 265 ], [ 265, 266 ], [ 265, 267 ], [ 267, 268 ], [ 268, 269 ], [ 268, 270 ], [ 267, 271 ], [ 255, 272 ], [ 272, 273 ], [ 273, 274 ], [ 274, 275 ], [ 273, 276 ], [ 250, 277 ], [ 277, 278 ], [ 278, 279 ], [ 279, 280 ], [ 278, 281 ], [ 223, 282 ], [ 282, 283 ], [ 283, 284 ], [ 221, 285 ], [ 285, 286 ], [ 664, 287 ], [ 287, 288 ], [ 287, 289 ], [ 289, 290 ], [ 287, 291 ], [ 291, 292 ], [ 287, 293 ], [ 293, 294 ], [ 293, 295 ], [ 295, 296 ], [ 296, 297 ], [ 296, 298 ], [ 293, 299 ], [ 299, 300 ], [ 287, 301 ], [ 301, 302 ], [ 301, 303 ], [ 303, 304 ], [ 304, 305 ], [ 304, 306 ], [ 301, 307 ], [ 307, 308 ], [ 287, 309 ], [ 309, 310 ], [ 309, 311 ], [ 311, 312 ], [ 312, 313 ], [ 313, 314 ], [ 314, 315 ], [ 314, 316 ], [ 313, 317 ], [ 317, 318 ], [ 318, 319 ], [ 319, 320 ], [ 312, 321 ], [ 321, 322 ], [ 321, 323 ], [ 311, 324 ], [ 324, 325 ], [ 325, 326 ], [ 326, 327 ], [ 287, 328 ], [ 328, 329 ], [ 328, 330 ], [ 330, 331 ], [ 331, 332 ], [ 332, 333 ], [ 333, 334 ], [ 332, 335 ], [ 335, 336 ], [ 287, 337 ], [ 337, 338 ], [ 337, 339 ], [ 339, 340 ], [ 340, 341 ], [ 341, 342 ], [ 342, 343 ], [ 341, 344 ], [ 344, 345 ], [ 287, 346 ], [ 346, 347 ], [ 346, 348 ], [ 348, 349 ], [ 349, 350 ], [ 350, 351 ], [ 351, 352 ], [ 287, 353 ], [ 353, 354 ], [ 353, 355 ], [ 355, 356 ], [ 356, 357 ], [ 357, 358 ], [ 358, 359 ], [ 357, 360 ], [ 360, 361 ], [ 287, 362 ], [ 362, 363 ], [ 362, 364 ], [ 364, 365 ], [ 365, 366 ], [ 365, 367 ], [ 364, 369 ], [ 369, 370 ], [ 370, 371 ], [ 371, 372 ], [ 371, 373 ], [ 369, 374 ], [ 374, 375 ], [ 374, 376 ], [ 376, 377 ], [ 376, 378 ], [ 369, 379 ], [ 379, 380 ], [ 380, 381 ], [ 369, 382 ], [ 382, 383 ], [ 383, 384 ], [ 384, 385 ], [ 384, 386 ], [ 383, 387 ], [ 387, 388 ], [ 364, 389 ], [ 389, 390 ], [ 362, 391 ], [ 391, 392 ], [ 287, 393 ], [ 393, 394 ], [ 393, 395 ], [ 395, 396 ], [ 396, 397 ], [ 396, 398 ], [ 395, 400 ], [ 400, 401 ], [ 401, 402 ], [ 402, 403 ], [ 402, 404 ], [ 400, 405 ], [ 405, 406 ], [ 405, 407 ], [ 400, 408 ], [ 408, 409 ], [ 409, 410 ], [ 400, 411 ], [ 411, 412 ], [ 412, 413 ], [ 413, 414 ], [ 413, 415 ], [ 412, 416 ], [ 416, 417 ], [ 395, 418 ], [ 418, 419 ], [ 393, 420 ], [ 420, 421 ], [ 287, 422 ], [ 422, 423 ], [ 422, 424 ], [ 424, 425 ], [ 425, 426 ], [ 426, 427 ], [ 427, 428 ], [ 664, 429 ], [ 429, 430 ], [ 429, 431 ], [ 431, 432 ], [ 429, 433 ], [ 433, 434 ], [ 429, 435 ], [ 435, 436 ], [ 435, 437 ], [ 437, 438 ], [ 438, 439 ], [ 439, 440 ], [ 439, 441 ], [ 438, 442 ], [ 437, 443 ], [ 443, 444 ], [ 444, 445 ], [ 444, 446 ], [ 443, 447 ], [ 435, 448 ], [ 448, 449 ], [ 435, 450 ], [ 450, 451 ], [ 429, 452 ], [ 452, 453 ], [ 452, 454 ], [ 454, 455 ], [ 455, 456 ], [ 456, 457 ], [ 457, 458 ], [ 458, 459 ], [ 459, 460 ], [ 460, 461 ], [ 460, 462 ], [ 459, 463 ], [ 458, 464 ], [ 464, 465 ], [ 464, 466 ], [ 429, 467 ], [ 467, 468 ], [ 467, 469 ], [ 469, 470 ], [ 470, 471 ], [ 471, 472 ], [ 472, 473 ], [ 472, 474 ], [ 471, 475 ], [ 475, 476 ], [ 475, 477 ], [ 470, 478 ], [ 478, 479 ], [ 479, 480 ], [ 480, 481 ], [ 480, 482 ], [ 479, 483 ], [ 483, 484 ], [ 483, 485 ], [ 470, 486 ], [ 486, 487 ], [ 487, 488 ], [ 488, 489 ], [ 489, 490 ], [ 489, 491 ], [ 488, 492 ], [ 492, 493 ], [ 492, 494 ], [ 467, 495 ], [ 495, 496 ], [ 429, 497 ], [ 497, 498 ], [ 497, 499 ], [ 499, 500 ], [ 500, 501 ], [ 501, 502 ], [ 501, 503 ], [ 500, 504 ], [ 504, 505 ], [ 505, 506 ], [ 499, 507 ], [ 507, 508 ], [ 508, 509 ], [ 509, 510 ], [ 510, 511 ], [ 508, 512 ], [ 512, 513 ], [ 513, 514 ], [ 507, 515 ], [ 515, 516 ], [ 516, 517 ], [ 499, 518 ], [ 518, 519 ], [ 518, 520 ], [ 499, 521 ], [ 521, 522 ], [ 522, 523 ], [ 523, 524 ], [ 524, 525 ], [ 524, 526 ], [ 523, 527 ], [ 527, 528 ], [ 527, 529 ], [ 522, 530 ], [ 530, 531 ], [ 531, 532 ], [ 531, 533 ], [ 530, 534 ], [ 534, 535 ], [ 534, 536 ], [ 497, 537 ], [ 537, 538 ], [ 429, 539 ], [ 664, 540 ], [ 540, 541 ], [ 540, 542 ], [ 542, 543 ], [ 540, 544 ], [ 544, 545 ], [ 540, 546 ], [ 546, 547 ], [ 540, 548 ], [ 548, 549 ], [ 548, 550 ], [ 550, 551 ], [ 551, 552 ], [ 552, 553 ], [ 552, 554 ], [ 551, 555 ], [ 550, 556 ], [ 556, 557 ], [ 557, 558 ], [ 557, 559 ], [ 556, 560 ], [ 550, 561 ], [ 561, 562 ], [ 562, 563 ], [ 562, 564 ], [ 561, 565 ], [ 548, 566 ], [ 566, 567 ], [ 548, 568 ], [ 568, 569 ], [ 548, 570 ], [ 570, 571 ], [ 540, 572 ], [ 572, 573 ], [ 572, 574 ], [ 574, 575 ], [ 575, 576 ], [ 576, 577 ], [ 577, 578 ], [ 577, 579 ], [ 576, 580 ], [ 580, 581 ], [ 580, 582 ], [ 575, 583 ], [ 583, 584 ], [ 584, 585 ], [ 585, 586 ], [ 585, 587 ], [ 584, 588 ], [ 588, 589 ], [ 588, 590 ], [ 575, 591 ], [ 591, 592 ], [ 592, 593 ], [ 593, 594 ], [ 594, 595 ], [ 594, 596 ], [ 593, 597 ], [ 597, 598 ], [ 597, 599 ], [ 592, 600 ], [ 600, 601 ], [ 601, 602 ], [ 602, 603 ], [ 602, 604 ], [ 601, 605 ], [ 605, 606 ], [ 605, 607 ], [ 592, 608 ], [ 608, 609 ], [ 609, 610 ], [ 610, 611 ], [ 610, 612 ], [ 609, 613 ], [ 613, 614 ], [ 613, 615 ], [ 572, 616 ], [ 616, 617 ], [ 540, 618 ], [ 618, 619 ], [ 618, 620 ], [ 620, 621 ], [ 621, 622 ], [ 622, 623 ], [ 623, 624 ], [ 624, 625 ], [ 624, 626 ], [ 623, 627 ], [ 627, 628 ], [ 627, 629 ], [ 622, 630 ], [ 630, 631 ], [ 631, 632 ], [ 631, 633 ], [ 630, 634 ], [ 634, 635 ], [ 634, 636 ], [ 618, 637 ], [ 637, 638 ], [ 540, 639 ], [ 664, 640 ], [ 640, 641 ], [ 640, 642 ], [ 642, 643 ], [ 640, 644 ], [ 644, 645 ], [ 640, 646 ], [ 646, 647 ], [ 646, 648 ], [ 648, 649 ], [ 649, 650 ], [ 650, 651 ], [ 650, 652 ], [ 649, 653 ], [ 648, 654 ], [ 654, 655 ], [ 655, 656 ], [ 655, 657 ], [ 654, 658 ], [ 646, 659 ], [ 659, 660 ], [ 646, 661 ], [ 661, 662 ], [ 0, 663 ], [ 663, 664 ], [ 663, 665 ] ]
[ "import java.io.*;\nimport java.util.*;\npublic class Main {\n static PrintWriter pw;\n static int[] visit;\n static int max;\n static int[] arr;\n static void dfs(int i, int c) {\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }\n public static long gcf(long x, long y) {\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }\n static int ceildiv(int x, int y){\n return x%y==0? x/y: x/y+1;\n }\n static int count1s(int x){\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }\n static void print(int n){\n while(n-->0)\n pw.print(0+\" \");\n }\n static boolean binary(String s){\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }\n public static void main(String[] args) throws Exception {\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }\n static class Scanner {\n StringTokenizer st;\n BufferedReader br;\n public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }\n\n public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }\n\n public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n public long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n public String nextLine() throws IOException {\n return br.readLine();\n }\n\n public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }\n public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }\n public boolean ready() throws IOException {\n return br.ready();\n }\n }\n static class Pair implements Comparable<Pair>{\n int x;\n int y;\n public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }\n public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }\n public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }\n }\n static class tuple implements Comparable<tuple>{\n int x;int y;int z;\n public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }\n public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }\n public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }\n }\n static class visit {\n int x;\n boolean y;\n public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }\n }\n}", "import java.io.*;", "io.*", "java", "import java.util.*;", "util.*", "java", "public class Main {\n static PrintWriter pw;\n static int[] visit;\n static int max;\n static int[] arr;\n static void dfs(int i, int c) {\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }\n public static long gcf(long x, long y) {\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }\n static int ceildiv(int x, int y){\n return x%y==0? x/y: x/y+1;\n }\n static int count1s(int x){\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }\n static void print(int n){\n while(n-->0)\n pw.print(0+\" \");\n }\n static boolean binary(String s){\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }\n public static void main(String[] args) throws Exception {\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }\n static class Scanner {\n StringTokenizer st;\n BufferedReader br;\n public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }\n\n public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }\n\n public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n public long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n public String nextLine() throws IOException {\n return br.readLine();\n }\n\n public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }\n public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }\n public boolean ready() throws IOException {\n return br.ready();\n }\n }\n static class Pair implements Comparable<Pair>{\n int x;\n int y;\n public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }\n public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }\n public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }\n }\n static class tuple implements Comparable<tuple>{\n int x;int y;int z;\n public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }\n public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }\n public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }\n }\n static class visit {\n int x;\n boolean y;\n public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }\n }\n}", "Main", "static PrintWriter pw;", "pw", "static int[] visit;", "visit", "static int max;", "max", "static int[] arr;", "arr", "static void dfs(int i, int c) {\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }", "dfs", "{\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }", "visit[i-1]=c", "visit[i-1]", "visit", "i-1", "i", "1", "c", "max=Math.max(c, max)", "max", "Math.max(c, max)", "Math.max", "Math", "c", "max", "int lim=arr.length/i;", "lim", "arr.length/i", "arr.length", "arr", "arr.length", "i", "for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }", "int j=2;", "int j=2;", "j", "2", "j<=lim", "j", "lim", "j++", "j++", "j", "{\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }", "{\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }", "if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }", "visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]", "visit[i*j-1]<c+1", "visit[i*j-1]", "visit", "i*j-1", "i*j", "i", "j", "1", "c+1", "c", "1", "arr[i*j-1]>arr[i-1]", "arr[i*j-1]", "arr", "i*j-1", "i*j", "i", "j", "1", "arr[i-1]", "arr", "i-1", "i", "1", "{\n dfs(i*j, c+1);\n }", "dfs(i*j, c+1)", "dfs", "i*j", "i", "j", "c+1", "c", "1", "int i", "i", "int c", "c", "public static long gcf(long x, long y) {\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }", "gcf", "{\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }", "while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }", "x%y!=0 && y%x!=0", "x%y!=0", "x%y", "x", "y", "0", "y%x!=0", "y%x", "y", "x", "0", "{\n if(x>y)\n x%=y;\n else\n y%=x;\n }", "if(x>y)\n x%=y;\n else\n y%=x;", "x>y", "x", "y", "x%=y", "x", "y", "y%=x", "y", "x", "return x>y? y:x;", "x>y? y:x", "x>y", "x", "y", "y", "x", "long x", "x", "long y", "y", "static int ceildiv(int x, int y){\n return x%y==0? x/y: x/y+1;\n }", "ceildiv", "{\n return x%y==0? x/y: x/y+1;\n }", "return x%y==0? x/y: x/y+1;", "x%y==0? x/y: x/y+1", "x%y==0", "x%y", "x", "y", "0", "x/y", "x", "y", "x/y+1", "x/y", "x", "y", "1", "int x", "x", "int y", "y", "static int count1s(int x){\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }", "count1s", "{\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }", "int ans=0;", "ans", "0", "while(x>0){\n ans+=(x&1);\n x>>=1;\n }", "x>0", "x", "0", "{\n ans+=(x&1);\n x>>=1;\n }", "ans+=(x&1)", "ans", "(x&1)", "x", "1", "x>>=1", "x", "1", "return ans;", "ans", "int x", "x", "static void print(int n){\n while(n-->0)\n pw.print(0+\" \");\n }", "print", "{\n while(n-->0)\n pw.print(0+\" \");\n }", "while(n-->0)\n pw.print(0+\" \");", "n-->0", "n--", "n", "0", "pw.print(0+\" \")", "pw.print", "pw", "0+\" \"", "0", "\" \"", "int n", "n", "static boolean binary(String s){\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }", "binary", "{\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }", "for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;", "int i=0;", "int i=0;", "i", "0", "i<s.length()", "i", "s.length()", "s.length", "s", "i++", "i++", "i", "if(s.charAt(i)>'1')\n return false;", "if(s.charAt(i)>'1')\n return false;", "s.charAt(i)>'1'", "s.charAt(i)", "s.charAt", "s", "i", "'1'", "return false;", "false", "return true;", "true", "String s", "s", "public static void main(String[] args) throws Exception {\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }", "main", "{\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }", "Scanner sc= new Scanner(System.in);", "sc", "new Scanner(System.in)", "pw = new PrintWriter(System.out)", "pw", "new PrintWriter(System.out)", "int a=sc.nextInt()", "a", "sc.nextInt()", "sc.nextInt", "sc", "b=sc.nextInt()", "b", "sc.nextInt()", "sc.nextInt", "sc", "c=sc.nextInt()", "c", "sc.nextInt()", "sc.nextInt", "sc", "k=sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }", "k>a", "k", "a", "{\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }", "if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }", "k>a+b", "k", "a+b", "a", "b", "{\n pw.println(a-(k-a-b));\n }", "pw.println(a-(k-a-b))", "pw.println", "pw", "a-(k-a-b)", "a", "(k-a-b)", "k-a-b", "k", "a", "b", "{\n pw.println(a);\n }", "pw.println(a)", "pw.println", "pw", "a", "{\n pw.println(k);\n }", "pw.println(k)", "pw.println", "pw", "k", "pw.close()", "pw.close", "pw", "String[] args", "args", "static class Scanner {\n StringTokenizer st;\n BufferedReader br;\n public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }\n\n public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }\n\n public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n public long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n public String nextLine() throws IOException {\n return br.readLine();\n }\n\n public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }\n public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }\n public boolean ready() throws IOException {\n return br.ready();\n }\n }", "Scanner", "StringTokenizer st;", "st", "BufferedReader br;", "br", "public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }", "Scanner", "{\n br = new BufferedReader(new InputStreamReader(s));\n }", "br = new BufferedReader(new InputStreamReader(s))", "br", "new BufferedReader(new InputStreamReader(s))", "InputStream s", "s", "public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }", "Scanner", "{\n br = new BufferedReader(r);\n }", "br = new BufferedReader(r)", "br", "new BufferedReader(r)", "FileReader r", "r", "public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }", "while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());", "st == null || !st.hasMoreTokens()", "st == null", "st", "null", "!st.hasMoreTokens()", "st.hasMoreTokens()", "st.hasMoreTokens", "st", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "public long nextLong() throws IOException {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "public String nextLine() throws IOException {\n return br.readLine();\n }", "nextLine", "{\n return br.readLine();\n }", "return br.readLine();", "br.readLine()", "br.readLine", "br", "public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }", "nextArr", "{\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }", "int[] arr = new int[n];", "arr", "new int[n]", "n", "for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();", "int i = 0;", "int i = 0;", "i", "0", "i < arr.length", "i", "arr.length", "arr", "arr.length", "i++", "i++", "i", "arr[i] = nextInt();", "arr[i] = nextInt()", "arr[i]", "arr", "i", "nextInt()", "nextInt", "return arr;", "arr", "int n", "n", "public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }", "nextsort", "{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }", "Integer[] arr=new Integer[n];", "arr", "new Integer[n]", "n", "for(int i=0; i<n; i++)\n arr[i]=nextInt();", "int i=0;", "int i=0;", "i", "0", "i<n", "i", "n", "i++", "i++", "i", "arr[i]=nextInt();", "arr[i]=nextInt()", "arr[i]", "arr", "i", "nextInt()", "nextInt", "return arr;", "arr", "int n", "n", "public boolean ready() throws IOException {\n return br.ready();\n }", "ready", "{\n return br.ready();\n }", "return br.ready();", "br.ready()", "br.ready", "br", "static class Pair implements Comparable<Pair>{\n int x;\n int y;\n public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }\n public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }\n public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }\n }", "Pair", "int x;", "x", "int y;", "y", "public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }", "Pair", "{\n this.x=x;\n this.y=y;\n }", "this.x=x", "this.x", "this", "this.x", "x", "this.y=y", "this.y", "this", "this.y", "y", "int x", "x", "int y", "y", "public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }", "hashCode", "{\n return (this.x+\"\"+this.y).hashCode();\n }", "return (this.x+\"\"+this.y).hashCode();", "(this.x+\"\"+this.y).hashCode()", "(this.x+\"\"+this.y).hashCode", "(this.x+\"\"+this.y)", "this.x+\"\"+this.y", "this.x", "this", "this.x", "\"\"", "this.y", "this", "this.y", "public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }", "compareTo", "{\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }", "if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }", "this.x!=other.x", "this.x", "this", "this.x", "other.x", "other", "other.x", "return this.x-other.x;", "this.x-other.x", "this.x", "this", "this.x", "other.x", "other", "other.x", "{\n return this.y-other.y;\n }", "return this.y-other.y;", "this.y-other.y", "this.y", "this", "this.y", "other.y", "other", "other.y", "Pair other", "other", "public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }", "equals", "{\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }", "if (obj == null) {\n return false;\n }", "obj == null", "obj", "null", "{\n return false;\n }", "return false;", "false", "if (this.getClass() != obj.getClass()) {\n return false;\n }", "this.getClass() != obj.getClass()", "this.getClass()", "this.getClass", "this", "obj.getClass()", "obj.getClass", "obj", "{\n return false;\n }", "return false;", "false", "Pair p = (Pair) obj;", "p", "(Pair) obj", "return this.x == p.x && this.y == p.y;", "this.x == p.x && this.y == p.y", "this.x == p.x", "this.x", "this", "this.x", "p.x", "p", "p.x", "this.y == p.y", "this.y", "this", "this.y", "p.y", "p", "p.y", "Object obj", "obj", "Comparable", "static class tuple implements Comparable<tuple>{\n int x;int y;int z;\n public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }\n public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }\n public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }\n }", "tuple", "int x;", "x", "int y;", "y", "int z;", "z", "public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }", "tuple", "{\n this.x=x;\n this.y=y;\n this.z=z;\n }", "this.x=x", "this.x", "this", "this.x", "x", "this.y=y", "this.y", "this", "this.y", "y", "this.z=z", "this.z", "this", "this.z", "z", "int x", "x", "int y", "y", "int z", "z", "public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }", "compareTo", "{\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }", "if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }", "this.x!=other.x", "this.x", "this", "this.x", "other.x", "other", "other.x", "return this.x-other.x;", "this.x-other.x", "this.x", "this", "this.x", "other.x", "other", "other.x", "{\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }", "if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;", "this.y!=other.y", "this.y", "this", "this.y", "other.y", "other", "other.y", "return this.y-other.y;", "this.y-other.y", "this.y", "this", "this.y", "other.y", "other", "other.y", "return this.z-other.z;", "this.z-other.z", "this.z", "this", "this.z", "other.z", "other", "other.z", "tuple other", "other", "public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }", "equal", "{\n return this.x==t.x && this.y==t.y;\n }", "return this.x==t.x && this.y==t.y;", "this.x==t.x && this.y==t.y", "this.x==t.x", "this.x", "this", "this.x", "t.x", "t", "t.x", "this.y==t.y", "this.y", "this", "this.y", "t.y", "t", "t.y", "tuple t", "t", "Comparable", "static class visit {\n int x;\n boolean y;\n public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }\n }", "visit", "int x;", "x", "boolean y;", "y", "public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }", "visit", "{\n this.x=x;\n this.y=y;\n }", "this.x=x", "this.x", "this", "this.x", "x", "this.y=y", "this.y", "this", "this.y", "y", "int x", "x", "boolean y", "y", "public class Main {\n static PrintWriter pw;\n static int[] visit;\n static int max;\n static int[] arr;\n static void dfs(int i, int c) {\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }\n public static long gcf(long x, long y) {\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }\n static int ceildiv(int x, int y){\n return x%y==0? x/y: x/y+1;\n }\n static int count1s(int x){\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }\n static void print(int n){\n while(n-->0)\n pw.print(0+\" \");\n }\n static boolean binary(String s){\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }\n public static void main(String[] args) throws Exception {\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }\n static class Scanner {\n StringTokenizer st;\n BufferedReader br;\n public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }\n\n public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }\n\n public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n public long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n public String nextLine() throws IOException {\n return br.readLine();\n }\n\n public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }\n public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }\n public boolean ready() throws IOException {\n return br.ready();\n }\n }\n static class Pair implements Comparable<Pair>{\n int x;\n int y;\n public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }\n public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }\n public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }\n }\n static class tuple implements Comparable<tuple>{\n int x;int y;int z;\n public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }\n public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }\n public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }\n }\n static class visit {\n int x;\n boolean y;\n public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }\n }\n}", "public class Main {\n static PrintWriter pw;\n static int[] visit;\n static int max;\n static int[] arr;\n static void dfs(int i, int c) {\n visit[i-1]=c;\n max=Math.max(c, max);\n int lim=arr.length/i;\n for(int j=2; j<=lim; j++){\n if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){\n dfs(i*j, c+1);\n }\n }\n }\n public static long gcf(long x, long y) {\n while(x%y!=0 && y%x!=0) {\n if(x>y)\n x%=y;\n else\n y%=x;\n }\n return x>y? y:x;\n }\n static int ceildiv(int x, int y){\n return x%y==0? x/y: x/y+1;\n }\n static int count1s(int x){\n int ans=0;\n while(x>0){\n ans+=(x&1);\n x>>=1;\n }\n return ans;\n }\n static void print(int n){\n while(n-->0)\n pw.print(0+\" \");\n }\n static boolean binary(String s){\n for(int i=0; i<s.length(); i++)\n if(s.charAt(i)>'1')\n return false;\n return true;\n }\n public static void main(String[] args) throws Exception {\n Scanner sc= new Scanner(System.in);\n pw = new PrintWriter(System.out);\n int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt();\n if(k>a){\n if(k>a+b){\n pw.println(a-(k-a-b));\n }else{\n pw.println(a);\n }\n }else{\n pw.println(k);\n }\n pw.close();\n }\n static class Scanner {\n StringTokenizer st;\n BufferedReader br;\n public Scanner(InputStream s) {\n br = new BufferedReader(new InputStreamReader(s));\n }\n\n public Scanner(FileReader r) {\n br = new BufferedReader(r);\n }\n\n public String next() throws IOException {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {\n return Integer.parseInt(next());\n }\n\n public long nextLong() throws IOException {\n return Long.parseLong(next());\n }\n\n public String nextLine() throws IOException {\n return br.readLine();\n }\n\n public double nextDouble() throws IOException {\n return Double.parseDouble(next());\n }\n\n public int[] nextArr(int n) throws IOException {\n int[] arr = new int[n];\n for (int i = 0; i < arr.length; i++)\n arr[i] = nextInt();\n return arr;\n }\n public Integer[] nextsort(int n) throws IOException{\n Integer[] arr=new Integer[n];\n for(int i=0; i<n; i++)\n arr[i]=nextInt();\n return arr;\n }\n public boolean ready() throws IOException {\n return br.ready();\n }\n }\n static class Pair implements Comparable<Pair>{\n int x;\n int y;\n public Pair(int x, int y) {\n this.x=x;\n this.y=y;\n }\n public int hashCode() {\n return (this.x+\"\"+this.y).hashCode();\n }\n public int compareTo(Pair other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n return this.y-other.y;\n }\n }\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n if (this.getClass() != obj.getClass()) {\n return false;\n }\n Pair p = (Pair) obj;\n return this.x == p.x && this.y == p.y;\n }\n }\n static class tuple implements Comparable<tuple>{\n int x;int y;int z;\n public tuple(int x, int y, int z){\n this.x=x;\n this.y=y;\n this.z=z;\n }\n public int compareTo(tuple other) {\n if(this.x!=other.x)\n return this.x-other.x;\n else {\n if(this.y!=other.y)\n return this.y-other.y;\n else\n return this.z-other.z;\n }\n }\n public boolean equal(tuple t){\n return this.x==t.x && this.y==t.y;\n }\n }\n static class visit {\n int x;\n boolean y;\n public visit(int x, boolean y){\n this.x=x;\n this.y=y;\n }\n }\n}", "Main" ]
import java.io.*; import java.util.*; public class Main { static PrintWriter pw; static int[] visit; static int max; static int[] arr; static void dfs(int i, int c) { visit[i-1]=c; max=Math.max(c, max); int lim=arr.length/i; for(int j=2; j<=lim; j++){ if(visit[i*j-1]<c+1 && arr[i*j-1]>arr[i-1]){ dfs(i*j, c+1); } } } public static long gcf(long x, long y) { while(x%y!=0 && y%x!=0) { if(x>y) x%=y; else y%=x; } return x>y? y:x; } static int ceildiv(int x, int y){ return x%y==0? x/y: x/y+1; } static int count1s(int x){ int ans=0; while(x>0){ ans+=(x&1); x>>=1; } return ans; } static void print(int n){ while(n-->0) pw.print(0+" "); } static boolean binary(String s){ for(int i=0; i<s.length(); i++) if(s.charAt(i)>'1') return false; return true; } public static void main(String[] args) throws Exception { Scanner sc= new Scanner(System.in); pw = new PrintWriter(System.out); int a=sc.nextInt(),b=sc.nextInt(),c=sc.nextInt(),k=sc.nextInt(); if(k>a){ if(k>a+b){ pw.println(a-(k-a-b)); }else{ pw.println(a); } }else{ pw.println(k); } pw.close(); } static class Scanner { StringTokenizer st; BufferedReader br; public Scanner(InputStream s) { br = new BufferedReader(new InputStreamReader(s)); } public Scanner(FileReader r) { br = new BufferedReader(r); } public String next() throws IOException { while (st == null || !st.hasMoreTokens()) st = new StringTokenizer(br.readLine()); return st.nextToken(); } public int nextInt() throws IOException { return Integer.parseInt(next()); } public long nextLong() throws IOException { return Long.parseLong(next()); } public String nextLine() throws IOException { return br.readLine(); } public double nextDouble() throws IOException { return Double.parseDouble(next()); } public int[] nextArr(int n) throws IOException { int[] arr = new int[n]; for (int i = 0; i < arr.length; i++) arr[i] = nextInt(); return arr; } public Integer[] nextsort(int n) throws IOException{ Integer[] arr=new Integer[n]; for(int i=0; i<n; i++) arr[i]=nextInt(); return arr; } public boolean ready() throws IOException { return br.ready(); } } static class Pair implements Comparable<Pair>{ int x; int y; public Pair(int x, int y) { this.x=x; this.y=y; } public int hashCode() { return (this.x+""+this.y).hashCode(); } public int compareTo(Pair other) { if(this.x!=other.x) return this.x-other.x; else { return this.y-other.y; } } public boolean equals(Object obj) { if (obj == null) { return false; } if (this.getClass() != obj.getClass()) { return false; } Pair p = (Pair) obj; return this.x == p.x && this.y == p.y; } } static class tuple implements Comparable<tuple>{ int x;int y;int z; public tuple(int x, int y, int z){ this.x=x; this.y=y; this.z=z; } public int compareTo(tuple other) { if(this.x!=other.x) return this.x-other.x; else { if(this.y!=other.y) return this.y-other.y; else return this.z-other.z; } } public boolean equal(tuple t){ return this.x==t.x && this.y==t.y; } } static class visit { int x; boolean y; public visit(int x, boolean y){ this.x=x; this.y=y; } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 2, 4, 18, 13, 13, 13, 4, 18, 13, 2, 2, 13, 13, 13, 17, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 74, 8 ], [ 74, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 11, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 20, 23 ], [ 23, 24 ], [ 24, 25 ], [ 11, 26 ], [ 26, 27 ], [ 26, 28 ], [ 28, 29 ], [ 29, 30 ], [ 28, 31 ], [ 31, 32 ], [ 32, 33 ], [ 11, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 37, 38 ], [ 36, 39 ], [ 39, 40 ], [ 40, 41 ], [ 11, 42 ], [ 42, 43 ], [ 42, 44 ], [ 44, 45 ], [ 45, 46 ], [ 44, 47 ], [ 47, 48 ], [ 48, 49 ], [ 11, 50 ], [ 50, 51 ], [ 51, 52 ], [ 50, 53 ], [ 53, 54 ], [ 54, 55 ], [ 55, 56 ], [ 54, 57 ], [ 54, 58 ], [ 53, 59 ], [ 59, 60 ], [ 60, 61 ], [ 59, 62 ], [ 63, 63 ], [ 63, 64 ], [ 63, 65 ], [ 63, 66 ], [ 59, 67 ], [ 11, 68 ], [ 68, 69 ], [ 69, 70 ], [ 9, 71 ], [ 71, 72 ], [ 0, 73 ], [ 73, 74 ], [ 73, 75 ] ]
[ "import java.io.PrintWriter;\nimport java.util.*;\n\npublic class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }\n}", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.util.*;", "util.*", "java", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }\n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "PrintWriter out = new PrintWriter(System.out);", "out", "new PrintWriter(System.out)", "int a = Integer.parseInt(sc.next());", "a", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int b = Integer.parseInt(sc.next());", "b", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int c = Integer.parseInt(sc.next());", "c", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int k = Integer.parseInt(sc.next());", "k", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "out.println(Math.min(a, k) - Math.max(k - a - b, 0))", "out.println", "out", "Math.min(a, k) - Math.max(k - a - b, 0)", "Math.min(a, k)", "Math.min", "Math", "a", "k", "Math.max(k - a - b, 0)", "Math.max", "Math", "k - a - b", "k - a - b", "k", "a", "b", "0", "out.flush()", "out.flush", "out", "String[] args", "args", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }\n}", "public class Main {\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n PrintWriter out = new PrintWriter(System.out);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n out.println(Math.min(a, k) - Math.max(k - a - b, 0));\n out.flush();\n }\n}", "Main" ]
import java.io.PrintWriter; import java.util.*; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); PrintWriter out = new PrintWriter(System.out); int a = Integer.parseInt(sc.next()); int b = Integer.parseInt(sc.next()); int c = Integer.parseInt(sc.next()); int k = Integer.parseInt(sc.next()); out.println(Math.min(a, k) - Math.max(k - a - b, 0)); out.flush(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 0, 13, 13, 30, 14, 2, 2, 13, 13, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 77, 5 ], [ 77, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 8, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 8, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 8, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 45, 49 ], [ 49, 50 ], [ 49, 51 ], [ 51, 52 ], [ 51, 53 ], [ 44, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 44, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 65, 67 ], [ 8, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 6, 74 ], [ 74, 75 ], [ 0, 76 ], [ 76, 77 ], [ 76, 78 ] ]
[ "import java.util.*;\npublic class Main {\n\tpublic static void main(String[] args) {\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String[] args) {\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }\n}", "Main", "public static void main(String[] args) {\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }", "main", "{\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int ans= 0;", "ans", "0", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "if (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}", "K<=A", "K", "A", "{\n\t\t\tans=K;\n\t\t}", "ans=K", "ans", "K", "{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}", "if (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}", "A<K&&K<=A+B", "A<K", "A", "K", "K<=A+B", "K", "A+B", "A", "B", "{\n\t\t\t\tans=A;\n\t\t\t}", "ans=A", "ans", "A", "{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}", "ans=A-(K-(A+B))", "ans", "A-(K-(A+B))", "A", "(K-(A+B))", "K", "(A+B)", "A", "B", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }\n}", "public class Main {\n\tpublic static void main(String[] args) {\n \tScanner sc = new Scanner(System.in);\n \tint ans= 0;\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tif (K<=A) {\n\t\t\tans=K;\n\t\t}\n\t\telse{\n\t\t\tif (A<K&&K<=A+B) {\n\t\t\t\tans=A;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tans=A-(K-(A+B));\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(ans);\n\t\t//System.out.print(ans);\n\t\t\n\n }\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int ans= 0; int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); if (K<=A) { ans=K; } else{ if (A<K&&K<=A+B) { ans=A; } else{ ans=A-(K-(A+B)); } } System.out.println(ans); //System.out.print(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 13, 17, 14, 2, 2, 13, 13, 2, 13, 2, 13, 13, 30, 0, 13, 2, 13, 17, 14, 2, 2, 2, 13, 13, 13, 2, 13, 2, 2, 13, 13, 13, 30, 0, 13, 2, 2, 13, 17, 2, 2, 13, 2, 13, 13, 40, 17, 14, 2, 2, 2, 13, 13, 13, 13, 30, 0, 13, 2, 2, 13, 17, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 130, 5 ], [ 130, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 54, 55 ], [ 54, 56 ], [ 47, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 64, 66 ], [ 57, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 70, 72 ], [ 57, 73 ], [ 73, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 75, 79 ], [ 74, 80 ], [ 80, 81 ], [ 80, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 82, 86 ], [ 73, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 90, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 97, 98 ], [ 97, 99 ], [ 94, 100 ], [ 100, 101 ], [ 73, 102 ], [ 102, 103 ], [ 103, 104 ], [ 104, 105 ], [ 105, 106 ], [ 105, 107 ], [ 104, 108 ], [ 103, 109 ], [ 102, 110 ], [ 110, 111 ], [ 111, 112 ], [ 111, 113 ], [ 113, 114 ], [ 114, 115 ], [ 114, 116 ], [ 113, 117 ], [ 117, 118 ], [ 117, 119 ], [ 119, 120 ], [ 8, 121 ], [ 121, 122 ], [ 122, 123 ], [ 123, 124 ], [ 123, 125 ], [ 121, 126 ], [ 6, 127 ], [ 127, 128 ], [ 0, 129 ], [ 129, 130 ], [ 129, 131 ] ]
[ "import java.util.Scanner;\n \npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int num1 = Integer.parseInt(sc.next());", "num1", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int num0 = Integer.parseInt(sc.next());", "num0", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int numMinus1 = Integer.parseInt(sc.next());", "numMinus1", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int numToSelect = Integer.parseInt(sc.next());", "numToSelect", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int sum = 0;", "sum", "0", "if(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }", "numToSelect <= num1", "numToSelect", "num1", "{\n \tsum = numToSelect * 1;\n }", "sum = numToSelect * 1", "sum", "numToSelect * 1", "numToSelect", "1", "if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }", "num1 < numToSelect && numToSelect <= (num1+num0)", "num1 < numToSelect", "num1", "numToSelect", "numToSelect <= (num1+num0)", "numToSelect", "(num1+num0)", "num1", "num0", "{\n sum = num1 * 1;\n }", "sum = num1 * 1", "sum", "num1 * 1", "num1", "1", "if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }", "(num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)", "(num1+num0) < numToSelect", "(num1+num0)", "num1", "num0", "numToSelect", "numToSelect <= (num1+num0+numMinus1)", "numToSelect", "(num1+num0+numMinus1)", "num1+num0+numMinus1", "num1", "num0", "numMinus1", "{\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }", "sum = num1 * 1 + (numToSelect-(num1+num0)) * -1", "sum", "num1 * 1 + (numToSelect-(num1+num0)) * -1", "num1 * 1", "num1", "1", "(numToSelect-(num1+num0)) * -1", "(numToSelect-(num1+num0))", "numToSelect", "(num1+num0)", "num1", "num0", "-1", "1", "if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }", "(num1+num0+numMinus1) < numToSelect", "(num1+num0+numMinus1)", "num1+num0+numMinus1", "num1", "num0", "numMinus1", "numToSelect", "{\n \tsum = num1 * 1 + numMinus1 * -1;\n }", "sum = num1 * 1 + numMinus1 * -1", "sum", "num1 * 1 + numMinus1 * -1", "num1 * 1", "num1", "1", "numMinus1 * -1", "numMinus1", "-1", "1", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n\tint num1 = Integer.parseInt(sc.next());\n\tint num0 = Integer.parseInt(sc.next());\n int numMinus1 = Integer.parseInt(sc.next());\n int numToSelect = Integer.parseInt(sc.next());\n\n int sum = 0;\n\tif(numToSelect <= num1){\n \tsum = numToSelect * 1;\n }else if(num1 < numToSelect && numToSelect <= (num1+num0)){\n sum = num1 * 1;\n }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){\n sum = num1 * 1 + (numToSelect-(num1+num0)) * -1;\n }else if((num1+num0+numMinus1) < numToSelect){\n \tsum = num1 * 1 + numMinus1 * -1;\n }\n\n System.out.println(sum);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int num1 = Integer.parseInt(sc.next()); int num0 = Integer.parseInt(sc.next()); int numMinus1 = Integer.parseInt(sc.next()); int numToSelect = Integer.parseInt(sc.next()); int sum = 0; if(numToSelect <= num1){ sum = numToSelect * 1; }else if(num1 < numToSelect && numToSelect <= (num1+num0)){ sum = num1 * 1; }else if((num1+num0) < numToSelect && numToSelect <= (num1+num0+numMinus1)){ sum = num1 * 1 + (numToSelect-(num1+num0)) * -1; }else if((num1+num0+numMinus1) < numToSelect){ sum = num1 * 1 + numMinus1 * -1; } System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 2, 2, 17, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 75, 5 ], [ 75, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 49, 51 ], [ 46, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 46, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 59, 65 ], [ 8, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 66, 71 ], [ 6, 72 ], [ 72, 73 ], [ 0, 74 ], [ 74, 75 ], [ 74, 76 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "sc.close()", "sc.close", "sc", "int ans = 0;", "ans", "0", "if(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}", "K<A", "K", "A", "{\n\t\t\tans = K;\n\t\t}", "ans = K", "ans", "K", "if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}", "K<=A+B", "K", "A+B", "A", "B", "{\n\t\t\tans = A;\n\t\t}", "ans = A", "ans", "A", "{\n\t\t\tans = 2*A+B-K;;\n\t\t}", "ans = 2*A+B-K", "ans", "2*A+B-K", "2*A+B", "2*A", "2", "A", "B", "K", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}\n\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\t\n\t\tsc.close();\n\t\t\n\t\tint ans = 0;\n\t\t\n\t\tif(K<A) {\n\t\t\tans = K;\n\t\t}else if(K<=A+B) {\n\t\t\tans = A;\n\t\t}else {\n\t\t\tans = 2*A+B-K;;\n\t\t}\n\t\t\n\t\tSystem.out.println(ans);\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); sc.close(); int ans = 0; if(K<A) { ans = K; }else if(K<=A+B) { ans = A; }else { ans = 2*A+B-K;; } System.out.println(ans); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 14, 2, 13, 17, 30, 0, 13, 17, 40, 13, 14, 2, 13, 17, 30, 0, 13, 17, 40, 13, 30, 0, 13, 17, 40, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 86, 8 ], [ 86, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 11, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 11, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 11, 35 ], [ 35, 36 ], [ 35, 37 ], [ 11, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 38, 43 ], [ 43, 44 ], [ 43, 45 ], [ 38, 46 ], [ 46, 47 ], [ 47, 48 ], [ 38, 49 ], [ 50, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 55, 59 ], [ 59, 60 ], [ 51, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 65, 69 ], [ 69, 70 ], [ 61, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 71, 75 ], [ 75, 76 ], [ 11, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 9, 83 ], [ 83, 84 ], [ 0, 85 ], [ 85, 86 ], [ 85, 87 ] ]
[ "import java.util.*;\nimport java.util.Arrays;\npublic class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }\n}", "import java.util.*;", "util.*", "java", "import java.util.Arrays;", "Arrays", "java.util", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }\n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int sum = 0;", "sum", "0", "for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }", "int i=0;", "int i=0;", "i", "0", "i<k", "i", "k", "i++", "i++", "i", "{\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }", "{\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }", "if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }", "a!=0", "a", "0", "{\n sum +=1;\n a--;\n }", "sum +=1", "sum", "1", "a--", "a", "if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }", "b!=0", "b", "0", "{\n sum += 0;\n b--;\n }", "sum += 0", "sum", "0", "b--", "b", "{\n sum -=1;\n c--;\n }", "sum -=1", "sum", "1", "c--", "c", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }\n}", "public class Main{\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int sum = 0;\n for(int i=0;i<k;i++){\n if(a!=0){\n sum +=1;\n a--;\n }\n else if(b!=0){\n sum += 0;\n b--;\n }\n else{\n sum -=1;\n c--;\n }\n }\n System.out.println(sum);\n\n \n \n\n \n }\n}", "Main" ]
import java.util.*; import java.util.Arrays; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int sum = 0; for(int i=0;i<k;i++){ if(a!=0){ sum +=1; a--; } else if(b!=0){ sum += 0; b--; } else{ sum -=1; c--; } } System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 4, 18, 13, 13, 13, 0, 13, 13, 0, 13, 13, 0, 13, 4, 18, 13, 13, 13, 0, 13, 13, 14, 2, 13, 17, 4, 18, 18, 13, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 79, 5 ], [ 79, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 37, 40 ], [ 37, 41 ], [ 8, 42 ], [ 42, 43 ], [ 42, 44 ], [ 8, 45 ], [ 45, 46 ], [ 45, 47 ], [ 8, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 51, 52 ], [ 50, 53 ], [ 50, 54 ], [ 8, 55 ], [ 55, 56 ], [ 55, 57 ], [ 8, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 58, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 73, 74 ], [ 73, 75 ], [ 6, 76 ], [ 76, 77 ], [ 0, 78 ], [ 78, 79 ], [ 78, 80 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }\n}", "Main", "public static void main(String[] args) {\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }", "main", "{\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }", "Scanner cin = new Scanner(System.in);", "cin", "new Scanner(System.in)", "int a = cin.nextInt();", "a", "cin.nextInt()", "cin.nextInt", "cin", "int b = cin.nextInt();", "b", "cin.nextInt()", "cin.nextInt", "cin", "int c = cin.nextInt();", "c", "cin.nextInt()", "cin.nextInt", "cin", "int k = cin.nextInt();", "k", "cin.nextInt()", "cin.nextInt", "cin", "int sum = 0;", "sum", "0", "int m = Math.min(a, k);", "m", "Math.min(a, k)", "Math.min", "Math", "a", "k", "sum+=m", "sum", "m", "k-=m", "k", "m", "m = Math.min(b, k)", "m", "Math.min(b, k)", "Math.min", "Math", "b", "k", "k-=m", "k", "m", "if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);", "k==0", "k", "0", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "System.out.println(sum-k)", "System.out.println", "System.out", "System", "System.out", "sum-k", "sum", "k", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }\n}", "public class Main {\n\n public static void main(String[] args) {\n Scanner cin = new Scanner(System.in);\n int a = cin.nextInt();\n int b = cin.nextInt();\n int c = cin.nextInt();\n int k = cin.nextInt();\n int sum = 0;\n int m = Math.min(a, k);\n sum+=m;\n k-=m;\n m = Math.min(b, k);\n k-=m;\n if(k==0)\n System.out.println(sum);\n else\n System.out.println(sum-k);\n\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner cin = new Scanner(System.in); int a = cin.nextInt(); int b = cin.nextInt(); int c = cin.nextInt(); int k = cin.nextInt(); int sum = 0; int m = Math.min(a, k); sum+=m; k-=m; m = Math.min(b, k); k-=m; if(k==0) System.out.println(sum); else System.out.println(sum-k); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 42, 2, 13, 17, 30, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 13, 0, 13, 2, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 13, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 2, 40, 17, 13, 0, 13, 2, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 13, 0, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 17, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 4, 18, 13, 29, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 253, 17 ], [ 253, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 21, 23 ], [ 20, 24 ], [ 24, 25 ], [ 24, 26 ], [ 20, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 20, 32 ], [ 32, 33 ], [ 32, 34 ], [ 34, 35 ], [ 35, 36 ], [ 20, 37 ], [ 37, 38 ], [ 37, 39 ], [ 39, 40 ], [ 40, 41 ], [ 20, 42 ], [ 42, 43 ], [ 42, 44 ], [ 44, 45 ], [ 45, 46 ], [ 20, 47 ], [ 47, 48 ], [ 47, 49 ], [ 20, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 50, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 60, 62 ], [ 55, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 66, 67 ], [ 66, 68 ], [ 63, 69 ], [ 69, 70 ], [ 69, 71 ], [ 71, 72 ], [ 71, 73 ], [ 55, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 75, 79 ], [ 79, 80 ], [ 79, 81 ], [ 74, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 85, 86 ], [ 85, 87 ], [ 82, 88 ], [ 88, 89 ], [ 88, 90 ], [ 54, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 92, 96 ], [ 96, 97 ], [ 96, 98 ], [ 91, 99 ], [ 99, 100 ], [ 100, 101 ], [ 100, 102 ], [ 102, 103 ], [ 102, 104 ], [ 91, 105 ], [ 105, 106 ], [ 106, 107 ], [ 107, 108 ], [ 107, 109 ], [ 106, 110 ], [ 110, 111 ], [ 110, 112 ], [ 105, 113 ], [ 113, 114 ], [ 114, 115 ], [ 114, 116 ], [ 54, 117 ], [ 117, 118 ], [ 118, 119 ], [ 119, 120 ], [ 119, 121 ], [ 118, 122 ], [ 122, 123 ], [ 122, 124 ], [ 117, 125 ], [ 125, 126 ], [ 126, 127 ], [ 126, 128 ], [ 128, 129 ], [ 128, 130 ], [ 130, 131 ], [ 131, 132 ], [ 130, 133 ], [ 125, 134 ], [ 134, 135 ], [ 134, 136 ], [ 136, 137 ], [ 136, 138 ], [ 117, 139 ], [ 139, 140 ], [ 140, 141 ], [ 141, 142 ], [ 141, 143 ], [ 140, 144 ], [ 144, 145 ], [ 144, 146 ], [ 139, 147 ], [ 147, 148 ], [ 148, 149 ], [ 148, 150 ], [ 150, 151 ], [ 150, 152 ], [ 147, 153 ], [ 153, 154 ], [ 153, 155 ], [ 20, 156 ], [ 156, 157 ], [ 157, 158 ], [ 158, 159 ], [ 158, 160 ], [ 156, 161 ], [ 18, 162 ], [ 162, 163 ], [ 0, 164 ], [ 164, 165 ], [ 164, 166 ], [ 166, 167 ], [ 164, 168 ], [ 168, 169 ], [ 164, 170 ], [ 170, 171 ], [ 170, 172 ], [ 172, 173 ], [ 173, 174 ], [ 173, 175 ], [ 164, 176 ], [ 176, 177 ], [ 176, 178 ], [ 178, 179 ], [ 179, 180 ], [ 180, 181 ], [ 181, 182 ], [ 181, 183 ], [ 180, 184 ], [ 184, 185 ], [ 185, 186 ], [ 186, 187 ], [ 179, 188 ], [ 188, 189 ], [ 189, 190 ], [ 190, 191 ], [ 190, 192 ], [ 192, 193 ], [ 193, 194 ], [ 194, 195 ], [ 189, 196 ], [ 196, 197 ], [ 197, 198 ], [ 197, 199 ], [ 178, 200 ], [ 200, 201 ], [ 201, 202 ], [ 202, 203 ], [ 164, 204 ], [ 204, 205 ], [ 204, 206 ], [ 206, 207 ], [ 207, 208 ], [ 208, 209 ], [ 209, 210 ], [ 208, 211 ], [ 211, 212 ], [ 164, 213 ], [ 213, 214 ], [ 213, 215 ], [ 215, 216 ], [ 216, 217 ], [ 217, 218 ], [ 218, 219 ], [ 217, 220 ], [ 220, 221 ], [ 164, 222 ], [ 222, 223 ], [ 222, 224 ], [ 224, 225 ], [ 225, 226 ], [ 226, 227 ], [ 227, 228 ], [ 226, 229 ], [ 229, 230 ], [ 164, 231 ], [ 231, 232 ], [ 231, 233 ], [ 233, 234 ], [ 234, 235 ], [ 234, 236 ], [ 233, 237 ], [ 237, 238 ], [ 238, 239 ], [ 238, 240 ], [ 240, 241 ], [ 241, 242 ], [ 242, 243 ], [ 237, 244 ], [ 244, 245 ], [ 245, 246 ], [ 245, 247 ], [ 247, 248 ], [ 248, 249 ], [ 233, 250 ], [ 250, 251 ], [ 0, 252 ], [ 252, 253 ], [ 252, 254 ] ]
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.io.PrintWriter;\nimport java.util.*;\npublic class Main {\n\tpublic static void main(String[] args)throws IOException {\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n}\n\n\n\n\n\nclass FastReader {\n\tBufferedReader br;\n\tStringTokenizer st;\n\n\tpublic FastReader() {\n\t\tbr = new BufferedReader(new\n\t\t InputStreamReader(System.in));\n\t}\n\n\tString next() {\n\t\twhile (st == null || !st.hasMoreElements()) {\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn st.nextToken();\n\t}\n\n\tint nextInt() {\n\t\treturn Integer.parseInt(next());\n\t}\n\n\tlong nextLong() {\n\t\treturn Long.parseLong(next());\n\t}\n\n\tdouble nextDouble() {\n\t\treturn Double.parseDouble(next());\n\t}\n\n\tString nextLine() {\n\t\tString str = \"\";\n\t\ttry {\n\t\t\tstr = br.readLine();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn str;\n\t}\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String[] args)throws IOException {\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n}", "Main", "public static void main(String[] args)throws IOException {\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}", "main", "{\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}", "FastReader sc = new FastReader();", "sc", "new FastReader()", "PrintWriter pw = new PrintWriter(System.out);", "pw", "new PrintWriter(System.out)", "long a = sc.nextLong();", "a", "sc.nextLong()", "sc.nextLong", "sc", "long b = sc.nextLong();", "b", "sc.nextLong()", "sc.nextLong", "sc", "long c = sc.nextLong();", "c", "sc.nextLong()", "sc.nextLong", "sc", "long k = sc.nextLong();", "k", "sc.nextLong()", "sc.nextLong", "sc", "long ans = 0;", "ans", "0", "while (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}", "k != 0", "k", "0", "{\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}", "if (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && a <= k", "k != 0", "k", "0", "a <= k", "a", "k", "{\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t}", "ans = ans + a", "ans", "ans + a", "ans", "a", "k = k - a", "k", "k - a", "k", "a", "if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && a > k", "k != 0", "k", "0", "a > k", "a", "k", "{\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}", "ans = ans + k", "ans", "ans + k", "ans", "k", "k = 0", "k", "0", "if (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && b <= k", "k != 0", "k", "0", "b <= k", "b", "k", "{\n\t\t\t\tk = k - b;\n\t\t\t}", "k = k - b", "k", "k - b", "k", "b", "if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && b > k", "k != 0", "k", "0", "b > k", "b", "k", "{\n\t\t\t\tk = 0;\n\t\t\t}", "k = 0", "k", "0", "if (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && c <= k", "k != 0", "k", "0", "c <= k", "c", "k", "{\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t}", "ans = ans + (-1) * c", "ans", "ans + (-1) * c", "ans", "(-1) * c", "(-1)", "1", "c", "k = k - c", "k", "k - c", "k", "c", "if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}", "k != 0 && c > k", "k != 0", "k", "0", "c > k", "c", "k", "{\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}", "ans = ans - k", "ans", "ans - k", "ans", "k", "k = 0", "k", "0", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "class FastReader {\n\tBufferedReader br;\n\tStringTokenizer st;\n\n\tpublic FastReader() {\n\t\tbr = new BufferedReader(new\n\t\t InputStreamReader(System.in));\n\t}\n\n\tString next() {\n\t\twhile (st == null || !st.hasMoreElements()) {\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn st.nextToken();\n\t}\n\n\tint nextInt() {\n\t\treturn Integer.parseInt(next());\n\t}\n\n\tlong nextLong() {\n\t\treturn Long.parseLong(next());\n\t}\n\n\tdouble nextDouble() {\n\t\treturn Double.parseDouble(next());\n\t}\n\n\tString nextLine() {\n\t\tString str = \"\";\n\t\ttry {\n\t\t\tstr = br.readLine();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn str;\n\t}\n}", "FastReader", "BufferedReader br;", "br", "StringTokenizer st;", "st", "public FastReader() {\n\t\tbr = new BufferedReader(new\n\t\t InputStreamReader(System.in));\n\t}", "FastReader", "{\n\t\tbr = new BufferedReader(new\n\t\t InputStreamReader(System.in));\n\t}", "br = new BufferedReader(new\n\t\t InputStreamReader(System.in))", "br", "new BufferedReader(new\n\t\t InputStreamReader(System.in))", "String next() {\n\t\twhile (st == null || !st.hasMoreElements()) {\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn st.nextToken();\n\t}", "next", "{\n\t\twhile (st == null || !st.hasMoreElements()) {\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn st.nextToken();\n\t}", "while (st == null || !st.hasMoreElements()) {\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}", "st == null || !st.hasMoreElements()", "st == null", "st", "null", "!st.hasMoreElements()", "st.hasMoreElements()", "st.hasMoreElements", "st", "{\n\t\t\ttry {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}", "try {\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}", "catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}", "IOException e", "{\n\t\t\t\te.printStackTrace();\n\t\t\t}", "e.printStackTrace()", "e.printStackTrace", "e", "{\n\t\t\t\tst = new StringTokenizer(br.readLine());\n\t\t\t}", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "int nextInt() {\n\t\treturn Integer.parseInt(next());\n\t}", "nextInt", "{\n\t\treturn Integer.parseInt(next());\n\t}", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "long nextLong() {\n\t\treturn Long.parseLong(next());\n\t}", "nextLong", "{\n\t\treturn Long.parseLong(next());\n\t}", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "double nextDouble() {\n\t\treturn Double.parseDouble(next());\n\t}", "nextDouble", "{\n\t\treturn Double.parseDouble(next());\n\t}", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "String nextLine() {\n\t\tString str = \"\";\n\t\ttry {\n\t\t\tstr = br.readLine();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn str;\n\t}", "nextLine", "{\n\t\tString str = \"\";\n\t\ttry {\n\t\t\tstr = br.readLine();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn str;\n\t}", "String str = \"\";", "str", "\"\"", "try {\n\t\t\tstr = br.readLine();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}", "catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}", "IOException e", "{\n\t\t\te.printStackTrace();\n\t\t}", "e.printStackTrace()", "e.printStackTrace", "e", "{\n\t\t\tstr = br.readLine();\n\t\t}", "str = br.readLine()", "str", "br.readLine()", "br.readLine", "br", "return str;", "str", "public class Main {\n\tpublic static void main(String[] args)throws IOException {\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args)throws IOException {\n\t\tFastReader sc = new FastReader();\n\t\tPrintWriter pw = new PrintWriter(System.out);\n\t\tlong a = sc.nextLong();\n\t\tlong b = sc.nextLong();\n\t\tlong c = sc.nextLong();\n\t\tlong k = sc.nextLong();\n\t\tlong ans = 0;\n\t\twhile (k != 0) {\n\t\t\tif (k != 0 && a <= k) {\n\t\t\t\tans = ans + a;\n\t\t\t\tk = k - a;\n\t\t\t} else if (k != 0 && a > k) {\n\t\t\t\tans = ans + k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && b <= k) {\n\t\t\t\tk = k - b;\n\t\t\t} else if (k != 0 && b > k) {\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t\tif (k != 0 && c <= k) {\n\t\t\t\tans = ans + (-1) * c;\n\t\t\t\tk = k - c;\n\t\t\t} else if (k != 0 && c > k) {\n\t\t\t\tans = ans - k;\n\t\t\t\tk = 0;\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(ans);\n\n\n\t}\n}", "Main" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.io.PrintWriter; import java.util.*; public class Main { public static void main(String[] args)throws IOException { FastReader sc = new FastReader(); PrintWriter pw = new PrintWriter(System.out); long a = sc.nextLong(); long b = sc.nextLong(); long c = sc.nextLong(); long k = sc.nextLong(); long ans = 0; while (k != 0) { if (k != 0 && a <= k) { ans = ans + a; k = k - a; } else if (k != 0 && a > k) { ans = ans + k; k = 0; } if (k != 0 && b <= k) { k = k - b; } else if (k != 0 && b > k) { k = 0; } if (k != 0 && c <= k) { ans = ans + (-1) * c; k = k - c; } else if (k != 0 && c > k) { ans = ans - k; k = 0; } } System.out.println(ans); } } class FastReader { BufferedReader br; StringTokenizer st; public FastReader() { br = new BufferedReader(new InputStreamReader(System.in)); } String next() { while (st == null || !st.hasMoreElements()) { try { st = new StringTokenizer(br.readLine()); } catch (IOException e) { e.printStackTrace(); } } return st.nextToken(); } int nextInt() { return Integer.parseInt(next()); } long nextLong() { return Long.parseLong(next()); } double nextDouble() { return Double.parseDouble(next()); } String nextLine() { String str = ""; try { str = br.readLine(); } catch (IOException e) { e.printStackTrace(); } return str; } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 42, 17, 30, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 3, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 17, 30, 3, 14, 2, 13, 13, 30, 0, 13, 17, 3, 30, 0, 13, 13, 14, 2, 13, 17, 30, 3, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 3, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 17, 30, 3, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 116, 5 ], [ 116, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 42, 46 ], [ 46, 47 ], [ 46, 48 ], [ 42, 49 ], [ 38, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 50, 54 ], [ 54, 55 ], [ 54, 56 ], [ 37, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 57, 61 ], [ 61, 62 ], [ 37, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 63, 67 ], [ 67, 68 ], [ 68, 69 ], [ 68, 70 ], [ 67, 71 ], [ 63, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 37, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 76, 80 ], [ 80, 81 ], [ 37, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 82, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 90, 92 ], [ 86, 93 ], [ 82, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 98, 100 ], [ 37, 101 ], [ 101, 102 ], [ 102, 103 ], [ 102, 104 ], [ 101, 105 ], [ 105, 106 ], [ 8, 107 ], [ 107, 108 ], [ 108, 109 ], [ 109, 110 ], [ 109, 111 ], [ 107, 112 ], [ 6, 113 ], [ 113, 114 ], [ 0, 115 ], [ 115, 116 ], [ 115, 117 ] ]
[ "import java.util.*;\npublic class Main{\n\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }\n}\n\n\n\n", "import java.util.*;", "util.*", "java", "public class Main{\n\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }\n}", "Main", "public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int cnt =0;", "cnt", "0", "while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }", "true", "{\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }", "if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }", "a>k", "a", "k", "{\n cnt+=k;\n k=0;\n break;\n }", "cnt+=k", "cnt", "k", "k=0", "k", "0", "break;", "{\n cnt+=a;\n k-=a;\n }", "cnt+=a", "cnt", "a", "k-=a", "k", "a", "if(k<=0){\n break;\n\n }", "k<=0", "k", "0", "{\n break;\n\n }", "break;", "if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }", "b>k", "b", "k", "{\n k=0;\n break;\n }", "k=0", "k", "0", "break;", "{\n k-=b;\n }", "k-=b", "k", "b", "if(k<=0){\n break;\n }", "k<=0", "k", "0", "{\n break;\n }", "break;", "if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }", "c>k", "c", "k", "{\n cnt-=k;\n k=0;\n break;\n }", "cnt-=k", "cnt", "k", "k=0", "k", "0", "break;", "{\n cnt-=c;\n k-=c;\n }", "cnt-=c", "cnt", "c", "k-=c", "k", "c", "if(k<=0){\n break;\n }", "k<=0", "k", "0", "{\n break;\n }", "break;", "System.out.println(cnt)", "System.out.println", "System.out", "System", "System.out", "cnt", "String[] args", "args", "public class Main{\n\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }\n}", "public class Main{\n\n public static void main(String[] args){\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int cnt =0;\n\n while(true){\n if(a>k){\n cnt+=k;\n k=0;\n break;\n }else{\n cnt+=a;\n k-=a;\n }\n if(k<=0){\n break;\n\n }\n if(b>k){\n k=0;\n break;\n }else{\n k-=b;\n }\n if(k<=0){\n break;\n }\n\n if(c>k){\n cnt-=k;\n k=0;\n break;\n }else{\n cnt-=c;\n k-=c;\n }\n if(k<=0){\n break;\n }\n\n\n\n }\n System.out.println(cnt);\n }\n}", "Main" ]
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int cnt =0; while(true){ if(a>k){ cnt+=k; k=0; break; }else{ cnt+=a; k-=a; } if(k<=0){ break; } if(b>k){ k=0; break; }else{ k-=b; } if(k<=0){ break; } if(c>k){ cnt-=k; k=0; break; }else{ cnt-=c; k-=c; } if(k<=0){ break; } } System.out.println(cnt); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 17, 13, 4, 18, 18, 13, 13, 13, 30, 0, 13, 2, 13, 13, 0, 13, 2, 17, 13, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 2, 13, 13, 0, 13, 2, 13, 2, 13, 17, 14, 2, 13, 17, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 2, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 115, 5 ], [ 115, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 42, 44 ], [ 39, 45 ], [ 45, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 45, 50 ], [ 35, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 54, 55 ], [ 54, 56 ], [ 51, 57 ], [ 57, 58 ], [ 57, 59 ], [ 59, 60 ], [ 59, 61 ], [ 51, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 66, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 67, 72 ], [ 62, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 76, 78 ], [ 73, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 83, 85 ], [ 73, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 91, 96 ], [ 86, 97 ], [ 97, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 100, 102 ], [ 102, 103 ], [ 102, 104 ], [ 104, 105 ], [ 97, 106 ], [ 106, 107 ], [ 107, 108 ], [ 108, 109 ], [ 108, 110 ], [ 106, 111 ], [ 6, 112 ], [ 112, 113 ], [ 0, 114 ], [ 114, 115 ], [ 114, 116 ] ]
[ "\n\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}", "main", "{\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int A = scan.nextInt();", "A", "scan.nextInt()", "scan.nextInt", "scan", "int B = scan.nextInt();", "B", "scan.nextInt()", "scan.nextInt", "scan", "int C = scan.nextInt();", "C", "scan.nextInt()", "scan.nextInt", "scan", "int K = scan.nextInt();", "K", "scan.nextInt()", "scan.nextInt", "scan", "int ans = 0;", "ans", "0", "if (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}", "A > K", "A", "K", "{\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t}", "ans = 1 * K", "ans", "1 * K", "1", "K", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}", "K = K - A", "K", "K - A", "K", "A", "ans = 1 * A", "ans", "1 * A", "1", "A", "if (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}", "K == 0", "K", "0", "{\n\t\t\t\tSystem.out.println(ans);\n\t\t\t}", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}", "K = K - B", "K", "K - B", "K", "B", "ans = ans + (B * 0)", "ans", "ans + (B * 0)", "ans", "(B * 0)", "B", "0", "if (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}", "K <= 0", "K", "0", "{\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}", "ans = ans + (K * -1)", "ans", "ans + (K * -1)", "ans", "(K * -1)", "K", "-1", "1", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}\n\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO 自動生成されたメソッド・スタブ\n\t\tScanner scan = new Scanner(System.in);\n\t\tint A = scan.nextInt();\n\t\tint B = scan.nextInt();\n\t\tint C = scan.nextInt();\n\t\tint K = scan.nextInt();\n\n\t\tint ans = 0;\n\n\t\tif (A > K) {\n\t\t\tans = 1 * K;\n\t\t\tSystem.out.println(ans);\n\t\t} else {\n\t\t\tK = K - A;\n\t\t\tans = 1 * A;\n\t\t\tif (K == 0) {\n\t\t\t\tSystem.out.println(ans);\n\t\t\t} else {\n\t\t\t\tK = K - B;\n\t\t\t\tans = ans + (B * 0);\n\t\t\t\tif (K <= 0) {\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t} else {\n\t\t\t\t\tans = ans + (K * -1);\n\t\t\t\t\tSystem.out.println(ans);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { // TODO 自動生成されたメソッド・スタブ Scanner scan = new Scanner(System.in); int A = scan.nextInt(); int B = scan.nextInt(); int C = scan.nextInt(); int K = scan.nextInt(); int ans = 0; if (A > K) { ans = 1 * K; System.out.println(ans); } else { K = K - A; ans = 1 * A; if (K == 0) { System.out.println(ans); } else { K = K - B; ans = ans + (B * 0); if (K <= 0) { System.out.println(ans); } else { ans = ans + (K * -1); System.out.println(ans); } } } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 41, 13, 41, 13, 41, 13, 41, 13, 17, 41, 13, 20, 0, 13, 4, 18, 13, 4, 18, 13, 0, 13, 4, 18, 13, 4, 18, 13, 0, 13, 4, 18, 13, 4, 18, 13, 0, 13, 4, 18, 13, 4, 18, 13, 42, 2, 2, 13, 17, 2, 13, 17, 30, 40, 13, 40, 13, 40, 13, 42, 2, 2, 13, 17, 2, 13, 17, 30, 40, 13, 40, 13, 42, 2, 2, 13, 17, 2, 13, 17, 30, 40, 13, 40, 13, 40, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 107, 5 ], [ 107, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 8, 11 ], [ 11, 12 ], [ 8, 13 ], [ 13, 14 ], [ 8, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 8, 23 ], [ 23, 24 ], [ 23, 25 ], [ 25, 26 ], [ 26, 27 ], [ 25, 28 ], [ 28, 29 ], [ 29, 30 ], [ 8, 31 ], [ 31, 32 ], [ 31, 33 ], [ 33, 34 ], [ 34, 35 ], [ 33, 36 ], [ 36, 37 ], [ 37, 38 ], [ 8, 39 ], [ 39, 40 ], [ 39, 41 ], [ 41, 42 ], [ 42, 43 ], [ 41, 44 ], [ 44, 45 ], [ 45, 46 ], [ 8, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 50, 51 ], [ 49, 52 ], [ 52, 53 ], [ 53, 54 ], [ 8, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 60, 62 ], [ 55, 63 ], [ 63, 64 ], [ 64, 65 ], [ 63, 66 ], [ 66, 67 ], [ 63, 68 ], [ 68, 69 ], [ 8, 70 ], [ 70, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 71, 75 ], [ 75, 76 ], [ 75, 77 ], [ 70, 78 ], [ 78, 79 ], [ 79, 80 ], [ 78, 81 ], [ 81, 82 ], [ 8, 83 ], [ 83, 84 ], [ 84, 85 ], [ 85, 86 ], [ 85, 87 ], [ 84, 88 ], [ 88, 89 ], [ 88, 90 ], [ 83, 91 ], [ 91, 92 ], [ 92, 93 ], [ 91, 94 ], [ 94, 95 ], [ 91, 96 ], [ 96, 97 ], [ 8, 98 ], [ 98, 99 ], [ 99, 100 ], [ 100, 101 ], [ 100, 102 ], [ 98, 103 ], [ 6, 104 ], [ 104, 105 ], [ 0, 106 ], [ 106, 107 ], [ 106, 108 ] ]
[ "\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}", "main", "{\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}", "int A", "A", "B", "B", "C", "C", "K;", "K", "int T = 0 ;", "T", "0", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "A = Integer.parseInt(sc.next())", "A", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "B = Integer.parseInt(sc.next())", "B", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "C = Integer.parseInt(sc.next())", "C", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "K = Integer.parseInt(sc.next())", "K", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "while(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}", "K != 0 && A != 0", "K != 0", "K", "0", "A != 0", "A", "0", "{\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}", "T++", "T", "A--", "A", "K--", "K", "while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}", "K != 0 && B != 0", "K != 0", "K", "0", "B != 0", "B", "0", "{\n\t\tB--;\n\t\tK--;\n\t}", "B--", "B", "K--", "K", "while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}", "K != 0 && C != 0", "K != 0", "K", "0", "C != 0", "C", "0", "{\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}", "T--", "T", "C--", "C", "K--", "K", "System.out.println(T)", "System.out.println", "System.out", "System", "System.out", "T", "String[] args", "args", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}\n\n}", "public class Main {\n\n\tpublic static void main(String[] args) {\n\t\tint A , B , C , K;\n\tint T = 0 ;\n\tScanner sc = new Scanner(System.in);\n\tA = Integer.parseInt(sc.next());\n\tB = Integer.parseInt(sc.next());\n\tC = Integer.parseInt(sc.next());\n\tK = Integer.parseInt(sc.next());\n\twhile(K != 0 && A != 0) {\n\t\tT++;\n\t\tA--;\n\t\tK--;\n\t}while(K != 0 && B != 0) {\n\t\tB--;\n\t\tK--;\n\t}while(K != 0 && C != 0) {\n\t\tT--;\n\t\tC--;\n\t\tK--;\n\t}\n\tSystem.out.println(T);\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { int A , B , C , K; int T = 0 ; Scanner sc = new Scanner(System.in); A = Integer.parseInt(sc.next()); B = Integer.parseInt(sc.next()); C = Integer.parseInt(sc.next()); K = Integer.parseInt(sc.next()); while(K != 0 && A != 0) { T++; A--; K--; }while(K != 0 && B != 0) { B--; K--; }while(K != 0 && C != 0) { T--; C--; K--; } System.out.println(T); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 17, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 82, 5 ], [ 82, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 43, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 51, 53 ], [ 47, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 54, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 8, 70 ], [ 70, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 70, 75 ], [ 8, 76 ], [ 76, 77 ], [ 77, 78 ], [ 6, 79 ], [ 79, 80 ], [ 0, 81 ], [ 81, 82 ], [ 81, 83 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}\n\n}", "Main", "public static void main(String[] args) {\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}", "main", "{\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}", "Scanner stdIn = new Scanner(System.in);", "stdIn", "new Scanner(System.in)", "int A= stdIn.nextInt();", "A", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "int B= stdIn.nextInt();", "B", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "int C= stdIn.nextInt();", "C", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "int K= stdIn.nextInt();", "K", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "int counter = 0;", "counter", "0", "if(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}", "A>=K", "A", "K", "{\n\t\t\tcounter += K;\n\t\t}", "counter += K", "counter", "K", "if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}", "K>A", "K", "A", "{\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}", "counter += A", "counter", "A", "K -= A", "K", "A", "if(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}", "K>B", "K", "B", "{\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}", "K -= B", "K", "B", "if(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}", "K>0", "K", "0", "{\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}", "counter -= K", "counter", "K", "System.out.println(counter)", "System.out.println", "System.out", "System", "System.out", "counter", "stdIn.close()", "stdIn.close", "stdIn", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}\n\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner stdIn = new Scanner(System.in);\n\n\t\tint A= stdIn.nextInt();\n\t\tint B= stdIn.nextInt();\n\t\tint C= stdIn.nextInt();\n\t\tint K= stdIn.nextInt();\n\t\tint counter = 0;\n\n\t\tif(A>=K) {\n\t\t\tcounter += K;\n\t\t}else if(K>A) {\n\t\t\tcounter += A;\n\t\t\tK -= A;\n\t\t\tif(K>B) {\n\t\t\t\tK -= B;\n\t\t\t\tif(K>0) {\n\t\t\t\t\tcounter -= K;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(counter);\n\n\t\tstdIn.close();\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); int A= stdIn.nextInt(); int B= stdIn.nextInt(); int C= stdIn.nextInt(); int K= stdIn.nextInt(); int counter = 0; if(A>=K) { counter += K; }else if(K>A) { counter += A; K -= A; if(K>B) { K -= B; if(K>0) { counter -= K; } } } System.out.println(counter); stdIn.close(); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 30, 0, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 4, 18, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 119, 5 ], [ 119, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 44, 46 ], [ 8, 47 ], [ 47, 48 ], [ 48, 49 ], [ 48, 50 ], [ 47, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 55, 60 ], [ 47, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 65, 67 ], [ 61, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 72, 73 ], [ 73, 74 ], [ 74, 75 ], [ 75, 76 ], [ 75, 77 ], [ 73, 78 ], [ 68, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 79, 83 ], [ 83, 84 ], [ 84, 85 ], [ 84, 86 ], [ 83, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 90, 91 ], [ 90, 92 ], [ 92, 93 ], [ 87, 94 ], [ 94, 95 ], [ 95, 96 ], [ 96, 97 ], [ 96, 98 ], [ 94, 99 ], [ 83, 100 ], [ 100, 101 ], [ 101, 102 ], [ 101, 103 ], [ 103, 104 ], [ 103, 105 ], [ 105, 106 ], [ 100, 107 ], [ 107, 108 ], [ 108, 109 ], [ 109, 110 ], [ 109, 111 ], [ 107, 112 ], [ 8, 113 ], [ 113, 114 ], [ 114, 115 ], [ 6, 116 ], [ 116, 117 ], [ 0, 118 ], [ 118, 119 ], [ 118, 120 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }\n\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = Integer.parseInt(sc.next());", "a", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int b = Integer.parseInt(sc.next());", "b", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int c = Integer.parseInt(sc.next());", "c", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int k = Integer.parseInt(sc.next());", "k", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int ans = 0;", "ans", "0", "if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }", "k <= a", "k", "a", "{\n ans += k;\n System.out.println(ans);\n }", "ans += k", "ans", "k", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }", "k -= a", "k", "a", "ans += a", "ans", "a", "if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }", "k <= b", "k", "b", "{\n System.out.println(ans);\n }", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }", "k -= b", "k", "b", "if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }", "k <= c", "k", "c", "{\n ans += k * -1;\n System.out.println(ans);\n }", "ans += k * -1", "ans", "k * -1", "k", "-1", "1", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "{\n ans += k * -1;\n System.out.println(ans);\n }", "ans += k * -1", "ans", "k * -1", "k", "-1", "1", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "sc.close()", "sc.close", "sc", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }\n\n}", "public class Main {\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a = Integer.parseInt(sc.next());\n int b = Integer.parseInt(sc.next());\n int c = Integer.parseInt(sc.next());\n int k = Integer.parseInt(sc.next());\n int ans = 0;\n if (k <= a) {\n ans += k;\n System.out.println(ans);\n } else {\n k -= a;\n ans += a;\n if (k <= b) {\n System.out.println(ans);\n } else {\n k -= b;\n if (k <= c) {\n ans += k * -1;\n System.out.println(ans);\n } else {\n ans += k * -1;\n System.out.println(ans);\n }\n }\n }\n\n sc.close();\n }\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = Integer.parseInt(sc.next()); int b = Integer.parseInt(sc.next()); int c = Integer.parseInt(sc.next()); int k = Integer.parseInt(sc.next()); int ans = 0; if (k <= a) { ans += k; System.out.println(ans); } else { k -= a; ans += a; if (k <= b) { System.out.println(ans); } else { k -= b; if (k <= c) { ans += k * -1; System.out.println(ans); } else { ans += k * -1; System.out.println(ans); } } } sc.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 2, 17, 17, 12, 13, 30, 41, 13, 20, 41, 13, 20, 4, 13, 13, 13, 4, 18, 13, 23, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 17, 30, 4, 18, 13, 13, 29, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 17, 14, 2, 13, 17, 30, 4, 18, 13, 13, 29, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 4, 18, 13, 13, 23, 13, 23, 13, 6, 13, 41, 13, 2, 17, 17, 41, 13, 41, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 0, 13, 20, 13, 0, 13, 0, 13, 17, 23, 13, 12, 13, 30, 41, 13, 20, 13, 41, 13, 17, 38, 5, 13, 30, 30, 41, 13, 4, 13, 42, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 0, 13, 4, 13, 42, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 30, 0, 18, 13, 40, 13, 13, 0, 13, 4, 13, 29, 20, 23, 13, 12, 13, 30, 41, 13, 17, 41, 13, 38, 5, 13, 30, 30, 41, 13, 4, 13, 42, 2, 13, 17, 0, 13, 4, 13, 0, 13, 2, 13, 17, 14, 13, 0, 13, 4, 13, 42, 2, 13, 17, 30, 0, 13, 2, 2, 2, 13, 17, 13, 17, 0, 13, 4, 13, 14, 13, 29, 40, 13, 29, 13, 12, 13, 30, 41, 13, 17, 41, 13, 38, 5, 13, 30, 30, 41, 13, 4, 13, 42, 2, 13, 17, 0, 13, 4, 13, 0, 13, 2, 13, 17, 14, 13, 0, 13, 4, 13, 42, 2, 13, 17, 30, 0, 13, 2, 2, 2, 13, 17, 13, 17, 0, 13, 4, 13, 14, 13, 29, 40, 13, 29, 13, 12, 13, 30, 38, 5, 13, 30, 30, 0, 13, 4, 18, 13, 13, 0, 13, 17, 13, 14, 2, 13, 40, 17, 0, 18, 13, 17, 40, 17, 12, 13, 30, 14, 2, 13, 13, 4, 13, 29, 18, 13, 40, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 4, 13, 12, 13, 30, 4, 13, 13, 23, 13, 12, 13, 30, 14, 2, 40, 13, 2, 4, 18, 13, 17, 17, 30, 4, 13, 30, 4, 13, 17, 23, 13, 12, 13, 30, 0, 13, 20, 12, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 509, 11 ], [ 509, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 14, 16 ], [ 509, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 20, 22 ], [ 19, 23 ], [ 23, 24 ], [ 23, 25 ], [ 19, 26 ], [ 26, 27 ], [ 26, 28 ], [ 26, 29 ], [ 19, 30 ], [ 30, 31 ], [ 31, 32 ], [ 17, 33 ], [ 33, 34 ], [ 509, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 40, 41 ], [ 41, 42 ], [ 37, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 46, 47 ], [ 37, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 51, 52 ], [ 37, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 37, 58 ], [ 58, 59 ], [ 58, 60 ], [ 37, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 65, 69 ], [ 69, 70 ], [ 69, 71 ], [ 61, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 72, 76 ], [ 76, 77 ], [ 76, 78 ], [ 37, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 79, 83 ], [ 83, 84 ], [ 84, 85 ], [ 85, 86 ], [ 84, 87 ], [ 83, 88 ], [ 37, 89 ], [ 89, 90 ], [ 90, 91 ], [ 90, 92 ], [ 89, 93 ], [ 93, 94 ], [ 94, 95 ], [ 94, 96 ], [ 89, 97 ], [ 97, 98 ], [ 98, 99 ], [ 98, 100 ], [ 37, 101 ], [ 101, 102 ], [ 102, 103 ], [ 102, 104 ], [ 101, 105 ], [ 105, 106 ], [ 106, 107 ], [ 107, 108 ], [ 106, 109 ], [ 105, 110 ], [ 37, 111 ], [ 111, 112 ], [ 112, 113 ], [ 112, 114 ], [ 111, 115 ], [ 115, 116 ], [ 116, 117 ], [ 116, 118 ], [ 111, 119 ], [ 119, 120 ], [ 120, 121 ], [ 120, 122 ], [ 37, 123 ], [ 123, 124 ], [ 124, 125 ], [ 123, 126 ], [ 35, 127 ], [ 127, 128 ], [ 35, 129 ], [ 129, 130 ], [ 509, 131 ], [ 131, 132 ], [ 131, 133 ], [ 133, 134 ], [ 133, 135 ], [ 135, 136 ], [ 135, 137 ], [ 131, 138 ], [ 138, 139 ], [ 131, 140 ], [ 140, 141 ], [ 131, 142 ], [ 142, 143 ], [ 131, 144 ], [ 144, 145 ], [ 131, 146 ], [ 146, 147 ], [ 146, 148 ], [ 148, 149 ], [ 149, 150 ], [ 149, 151 ], [ 148, 152 ], [ 152, 153 ], [ 152, 154 ], [ 148, 156 ], [ 156, 157 ], [ 156, 158 ], [ 158, 159 ], [ 158, 160 ], [ 146, 161 ], [ 161, 162 ], [ 131, 163 ], [ 163, 164 ], [ 163, 165 ], [ 165, 166 ], [ 166, 167 ], [ 166, 168 ], [ 165, 170 ], [ 170, 171 ], [ 170, 172 ], [ 165, 173 ], [ 173, 174 ], [ 174, 175 ], [ 174, 176 ], [ 173, 177 ], [ 177, 178 ], [ 178, 179 ], [ 178, 180 ], [ 180, 181 ], [ 177, 182 ], [ 182, 183 ], [ 184, 184 ], [ 184, 185 ], [ 185, 186 ], [ 185, 187 ], [ 184, 188 ], [ 188, 189 ], [ 188, 190 ], [ 184, 191 ], [ 191, 192 ], [ 191, 193 ], [ 182, 194 ], [ 194, 195 ], [ 194, 196 ], [ 196, 197 ], [ 177, 198 ], [ 198, 199 ], [ 200, 200 ], [ 200, 201 ], [ 201, 202 ], [ 201, 203 ], [ 200, 204 ], [ 204, 205 ], [ 204, 206 ], [ 200, 207 ], [ 207, 208 ], [ 207, 209 ], [ 198, 210 ], [ 210, 211 ], [ 211, 212 ], [ 212, 213 ], [ 212, 214 ], [ 214, 215 ], [ 211, 216 ], [ 210, 217 ], [ 217, 218 ], [ 217, 219 ], [ 219, 220 ], [ 165, 221 ], [ 221, 222 ], [ 163, 223 ], [ 223, 224 ], [ 131, 225 ], [ 225, 226 ], [ 225, 227 ], [ 227, 228 ], [ 228, 229 ], [ 228, 230 ], [ 227, 231 ], [ 231, 232 ], [ 227, 233 ], [ 233, 234 ], [ 234, 235 ], [ 234, 236 ], [ 233, 237 ], [ 237, 238 ], [ 238, 239 ], [ 238, 240 ], [ 240, 241 ], [ 237, 242 ], [ 242, 243 ], [ 243, 244 ], [ 243, 245 ], [ 242, 246 ], [ 246, 247 ], [ 246, 248 ], [ 248, 249 ], [ 237, 250 ], [ 250, 251 ], [ 250, 252 ], [ 252, 253 ], [ 252, 254 ], [ 237, 255 ], [ 255, 256 ], [ 255, 257 ], [ 257, 258 ], [ 257, 259 ], [ 259, 260 ], [ 237, 261 ], [ 261, 262 ], [ 262, 263 ], [ 262, 264 ], [ 261, 265 ], [ 265, 266 ], [ 266, 267 ], [ 266, 268 ], [ 268, 269 ], [ 269, 270 ], [ 270, 271 ], [ 270, 272 ], [ 269, 273 ], [ 268, 274 ], [ 265, 275 ], [ 275, 276 ], [ 275, 277 ], [ 277, 278 ], [ 237, 279 ], [ 279, 280 ], [ 279, 281 ], [ 281, 282 ], [ 282, 283 ], [ 227, 284 ], [ 284, 285 ], [ 131, 286 ], [ 286, 287 ], [ 286, 288 ], [ 288, 289 ], [ 289, 290 ], [ 289, 291 ], [ 288, 292 ], [ 292, 293 ], [ 288, 294 ], [ 294, 295 ], [ 295, 296 ], [ 295, 297 ], [ 294, 298 ], [ 298, 299 ], [ 299, 300 ], [ 299, 301 ], [ 301, 302 ], [ 298, 303 ], [ 303, 304 ], [ 304, 305 ], [ 304, 306 ], [ 303, 307 ], [ 307, 308 ], [ 307, 309 ], [ 309, 310 ], [ 298, 311 ], [ 311, 312 ], [ 311, 313 ], [ 313, 314 ], [ 313, 315 ], [ 298, 316 ], [ 316, 317 ], [ 316, 318 ], [ 318, 319 ], [ 318, 320 ], [ 320, 321 ], [ 298, 322 ], [ 322, 323 ], [ 323, 324 ], [ 323, 325 ], [ 322, 326 ], [ 326, 327 ], [ 327, 328 ], [ 327, 329 ], [ 329, 330 ], [ 330, 331 ], [ 331, 332 ], [ 331, 333 ], [ 330, 334 ], [ 329, 335 ], [ 326, 336 ], [ 336, 337 ], [ 336, 338 ], [ 338, 339 ], [ 298, 340 ], [ 340, 341 ], [ 340, 342 ], [ 342, 343 ], [ 343, 344 ], [ 288, 345 ], [ 345, 346 ], [ 131, 347 ], [ 347, 348 ], [ 347, 349 ], [ 349, 350 ], [ 350, 351 ], [ 351, 352 ], [ 351, 353 ], [ 350, 354 ], [ 354, 355 ], [ 355, 356 ], [ 355, 357 ], [ 357, 358 ], [ 358, 359 ], [ 357, 360 ], [ 357, 361 ], [ 361, 362 ], [ 361, 363 ], [ 357, 364 ], [ 349, 365 ], [ 365, 366 ], [ 366, 367 ], [ 366, 368 ], [ 368, 369 ], [ 365, 370 ], [ 370, 371 ], [ 371, 372 ], [ 371, 373 ], [ 370, 374 ], [ 374, 375 ], [ 131, 376 ], [ 376, 377 ], [ 376, 378 ], [ 378, 379 ], [ 379, 380 ], [ 380, 381 ], [ 380, 382 ], [ 379, 383 ], [ 383, 384 ], [ 378, 385 ], [ 385, 386 ], [ 386, 387 ], [ 386, 388 ], [ 388, 389 ], [ 509, 390 ], [ 390, 391 ], [ 390, 392 ], [ 392, 393 ], [ 390, 394 ], [ 394, 395 ], [ 390, 396 ], [ 396, 397 ], [ 396, 398 ], [ 398, 399 ], [ 399, 400 ], [ 390, 401 ], [ 401, 402 ], [ 401, 403 ], [ 403, 404 ], [ 404, 405 ], [ 404, 406 ], [ 401, 407 ], [ 407, 408 ], [ 390, 409 ], [ 409, 410 ], [ 409, 411 ], [ 411, 412 ], [ 412, 413 ], [ 413, 414 ], [ 414, 415 ], [ 413, 416 ], [ 416, 417 ], [ 417, 418 ], [ 418, 419 ], [ 417, 420 ], [ 416, 421 ], [ 412, 422 ], [ 422, 423 ], [ 423, 424 ], [ 412, 425 ], [ 425, 426 ], [ 426, 427 ], [ 426, 428 ], [ 409, 429 ], [ 429, 430 ], [ 390, 431 ], [ 431, 432 ], [ 431, 433 ], [ 433, 434 ], [ 434, 435 ], [ 434, 436 ], [ 390, 437 ], [ 437, 438 ], [ 437, 439 ], [ 439, 440 ], [ 440, 441 ], [ 441, 442 ], [ 441, 443 ], [ 443, 444 ], [ 444, 445 ], [ 445, 446 ], [ 440, 447 ], [ 447, 448 ], [ 448, 449 ], [ 448, 450 ], [ 437, 451 ], [ 451, 452 ], [ 390, 453 ], [ 453, 454 ], [ 453, 455 ], [ 455, 456 ], [ 456, 457 ], [ 457, 458 ], [ 458, 459 ], [ 458, 460 ], [ 457, 461 ], [ 461, 462 ], [ 462, 463 ], [ 463, 464 ], [ 456, 465 ], [ 465, 466 ], [ 466, 467 ], [ 467, 468 ], [ 467, 469 ], [ 469, 470 ], [ 470, 471 ], [ 471, 472 ], [ 466, 473 ], [ 473, 474 ], [ 474, 475 ], [ 474, 476 ], [ 455, 477 ], [ 477, 478 ], [ 478, 479 ], [ 479, 480 ], [ 390, 481 ], [ 481, 482 ], [ 481, 483 ], [ 483, 484 ], [ 484, 485 ], [ 485, 486 ], [ 486, 487 ], [ 485, 488 ], [ 488, 489 ], [ 390, 490 ], [ 490, 491 ], [ 490, 492 ], [ 492, 493 ], [ 493, 494 ], [ 494, 495 ], [ 495, 496 ], [ 494, 497 ], [ 497, 498 ], [ 390, 499 ], [ 499, 500 ], [ 499, 501 ], [ 501, 502 ], [ 502, 503 ], [ 503, 504 ], [ 504, 505 ], [ 503, 506 ], [ 506, 507 ], [ 0, 508 ], [ 508, 509 ], [ 508, 510 ] ]
[ "import java.io.*;\nimport java.math.BigInteger;\nimport java.util.*;\n\n\npublic class Main {\n\n static long mod = ((long) (1E9 + 7));\n\n public static void main(String[] args) {\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }\n\n\n static void solve(FastScanner in, PrintWriter out) {\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }\n\n static class Parser {\n final private int BUFFER_SIZE = 1 << 16;\n private DataInputStream din;\n private byte[] buffer;\n private int bufferPointer, bytesRead;\n\n public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }\n\n public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }\n\n public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }\n\n private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }\n }\n\n\n static class FastScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public FastScanner() {\n init();\n }\n\n public FastScanner(String name) {\n init(name);\n }\n\n public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }\n\n private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }\n\n public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(nextToken());\n }\n\n\n public long nextLong() {\n return Long.parseLong(nextToken());\n }\n\n public double nextDouble() {\n return Double.parseDouble(nextToken());\n }\n\n }\n\n\n}", "import java.io.*;", "io.*", "java", "import java.math.BigInteger;", "BigInteger", "java.math", "import java.util.*;", "util.*", "java", "public class Main {\n\n static long mod = ((long) (1E9 + 7));\n\n public static void main(String[] args) {\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }\n\n\n static void solve(FastScanner in, PrintWriter out) {\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }\n\n static class Parser {\n final private int BUFFER_SIZE = 1 << 16;\n private DataInputStream din;\n private byte[] buffer;\n private int bufferPointer, bytesRead;\n\n public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }\n\n public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }\n\n public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }\n\n private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }\n }\n\n\n static class FastScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public FastScanner() {\n init();\n }\n\n public FastScanner(String name) {\n init(name);\n }\n\n public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }\n\n private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }\n\n public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(nextToken());\n }\n\n\n public long nextLong() {\n return Long.parseLong(nextToken());\n }\n\n public double nextDouble() {\n return Double.parseDouble(nextToken());\n }\n\n }\n\n\n}", "Main", "static long mod = ((long) (1E9 + 7));", "mod", "((long) (1E9 + 7))", "1E9", "7", "public static void main(String[] args) {\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }", "main", "{\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }", "FastScanner scr = new FastScanner();", "scr", "new FastScanner()", "PrintWriter out = new PrintWriter(System.out, true);", "out", "new PrintWriter(System.out, true)", "solve(scr, out)", "solve", "scr", "out", "out.close()", "out.close", "out", "String[] args", "args", "static void solve(FastScanner in, PrintWriter out) {\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }", "solve", "{\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }", "long A = in.nextLong();", "A", "in.nextLong()", "in.nextLong", "in", "long B = in.nextLong();", "B", "in.nextLong()", "in.nextLong", "in", "long C = in.nextLong();", "C", "in.nextLong()", "in.nextLong", "in", "long K = in.nextLong();", "K", "in.nextLong()", "in.nextLong", "in", "long S = 0;", "S", "0", "if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }", "A <= K", "A", "K", "{\n S += A;\n K -= A;\n\n }", "S += A", "S", "A", "K -= A", "K", "A", "{\n S += K;\n K = 0;\n }", "S += K", "S", "K", "K = 0", "K", "0", "if (K == 0) {\n out.println(S);\n return;\n }", "K == 0", "K", "0", "{\n out.println(S);\n return;\n }", "out.println(S)", "out.println", "out", "S", "return;", "if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }", "B <= K", "B", "K", "{\n K -= B;\n }", "K -= B", "K", "B", "{\n K = 0;\n }", "K = 0", "K", "0", "if (K == 0) {\n out.println(S);\n return;\n }", "K == 0", "K", "0", "{\n out.println(S);\n return;\n }", "out.println(S)", "out.println", "out", "S", "return;", "if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }", "C <= K", "C", "K", "{\n S -= C;\n }", "S -= C", "S", "C", "{\n S -= K;\n }", "S -= K", "S", "K", "out.println(S)", "out.println", "out", "S", "FastScanner in", "in", "PrintWriter out", "out", "static class Parser {\n final private int BUFFER_SIZE = 1 << 16;\n private DataInputStream din;\n private byte[] buffer;\n private int bufferPointer, bytesRead;\n\n public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }\n\n public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }\n\n public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }\n\n private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }\n }", "Parser", "final private int BUFFER_SIZE = 1 << 16;", "BUFFER_SIZE", "1 << 16", "1", "16", "private DataInputStream din;", "din", "private byte[] buffer;", "buffer", "private int bufferPointer", "bufferPointer", "bytesRead;", "bytesRead", "public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }", "Parser", "{\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }", "din = new DataInputStream(in)", "din", "new DataInputStream(in)", "buffer = new byte[BUFFER_SIZE]", "buffer", "new byte[BUFFER_SIZE]", "BUFFER_SIZE", "bufferPointer = bytesRead = 0", "bufferPointer", "bytesRead = 0", "bytesRead", "0", "InputStream in", "in", "public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }", "nextString", "{\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }", "byte[] ch = new byte[maxSize];", "ch", "new byte[maxSize]", "maxSize", "int point = 0;", "point", "0", "try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }", "catch (Exception e) {\n }", "Exception e", "{\n }", "{\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n }", "byte c = read();", "c", "read()", "read", "while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();", "c == ' ' || c == '\\n' || c == '\\r'", "c == ' ' || c == '\\n' || c == '\\r'", "c == ' '", "c", "' '", "c == '\\n'", "c", "'\\n'", "c == '\\r'", "c", "'\\r'", "c = read()", "c", "read()", "read", "while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }", "c != ' ' && c != '\\n' && c != '\\r'", "c != ' ' && c != '\\n' && c != '\\r'", "c != ' '", "c", "' '", "c != '\\n'", "c", "'\\n'", "c != '\\r'", "c", "'\\r'", "{\n ch[point++] = c;\n c = read();\n }", "ch[point++] = c", "ch[point++]", "ch", "point++", "point", "c", "c = read()", "c", "read()", "read", "return new String(ch, 0, point);", "new String(ch, 0, point)", "int maxSize", "maxSize", "public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }", "nextInt", "{\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }", "int ret = 0;", "ret", "0", "boolean neg;", "neg", "try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }", "catch (Exception e) {\n }", "Exception e", "{\n }", "{\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n }", "byte c = read();", "c", "read()", "read", "while (c <= ' ')\n c = read();", "c <= ' '", "c", "' '", "c = read()", "c", "read()", "read", "neg = c == '-'", "neg", "c == '-'", "c", "'-'", "if (neg)\n c = read();", "neg", "c = read()", "c", "read()", "read", "do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');", "c > ' '", "c", "' '", "{\n ret = ret * 10 + c - '0';\n c = read();\n }", "ret = ret * 10 + c - '0'", "ret", "ret * 10 + c - '0'", "ret * 10 + c", "ret * 10", "ret", "10", "c", "'0'", "c = read()", "c", "read()", "read", "if (neg) return -ret;", "neg", "return -ret;", "-ret", "ret", "return ret;", "ret", "public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }", "nextLong", "{\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }", "long ret = 0;", "ret", "0", "boolean neg;", "neg", "try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }", "catch (Exception e) {\n }", "Exception e", "{\n }", "{\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n }", "byte c = read();", "c", "read()", "read", "while (c <= ' ')\n c = read();", "c <= ' '", "c", "' '", "c = read()", "c", "read()", "read", "neg = c == '-'", "neg", "c == '-'", "c", "'-'", "if (neg)\n c = read();", "neg", "c = read()", "c", "read()", "read", "do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');", "c > ' '", "c", "' '", "{\n ret = ret * 10 + c - '0';\n c = read();\n }", "ret = ret * 10 + c - '0'", "ret", "ret * 10 + c - '0'", "ret * 10 + c", "ret * 10", "ret", "10", "c", "'0'", "c = read()", "c", "read()", "read", "if (neg) return -ret;", "neg", "return -ret;", "-ret", "ret", "return ret;", "ret", "private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }", "fillBuffer", "{\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }", "try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }", "catch (Exception e) {\n }", "Exception e", "{\n }", "{\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n }", "bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE)", "bytesRead", "din.read(buffer, bufferPointer = 0, BUFFER_SIZE)", "din.read", "din", "buffer", "bufferPointer = 0", "bufferPointer", "0", "BUFFER_SIZE", "if (bytesRead == -1) buffer[0] = -1;", "bytesRead == -1", "bytesRead", "-1", "1", "buffer[0] = -1", "buffer[0]", "buffer", "0", "-1", "1", "private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }", "read", "{\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }", "if (bufferPointer == bytesRead) fillBuffer();", "bufferPointer == bytesRead", "bufferPointer", "bytesRead", "fillBuffer()", "fillBuffer", "return buffer[bufferPointer++];", "buffer[bufferPointer++]", "buffer", "bufferPointer++", "bufferPointer", "static class FastScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public FastScanner() {\n init();\n }\n\n public FastScanner(String name) {\n init(name);\n }\n\n public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }\n\n private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }\n\n public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(nextToken());\n }\n\n\n public long nextLong() {\n return Long.parseLong(nextToken());\n }\n\n public double nextDouble() {\n return Double.parseDouble(nextToken());\n }\n\n }", "FastScanner", "BufferedReader br;", "br", "StringTokenizer st;", "st", "public FastScanner() {\n init();\n }", "FastScanner", "{\n init();\n }", "init()", "init", "public FastScanner(String name) {\n init(name);\n }", "FastScanner", "{\n init(name);\n }", "init(name)", "init", "name", "String name", "name", "public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }", "FastScanner", "{\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }", "if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }", "!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null", "!isOnlineJudge", "isOnlineJudge", "System.getProperty(\"ONLINE_JUDGE\") != null", "System.getProperty(\"ONLINE_JUDGE\")", "System.getProperty", "System", "\"ONLINE_JUDGE\"", "null", "{\n init();\n }", "init()", "init", "{\n init(\"input.txt\");\n }", "init(\"input.txt\")", "init", "\"input.txt\"", "boolean isOnlineJudge", "isOnlineJudge", "private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "init", "{\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "br = new BufferedReader(new InputStreamReader(System.in))", "br", "new BufferedReader(new InputStreamReader(System.in))", "private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }", "init", "{\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }", "try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }", "catch (FileNotFoundException e) {\n e.printStackTrace();\n }", "FileNotFoundException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n br = new BufferedReader(new FileReader(name));\n }", "br = new BufferedReader(new FileReader(name))", "br", "new BufferedReader(new FileReader(name))", "String name", "name", "public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "nextToken", "{\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "st == null || !st.hasMoreElements()", "st == null", "st", "null", "!st.hasMoreElements()", "st.hasMoreElements()", "st.hasMoreElements", "st", "{\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n st = new StringTokenizer(br.readLine());\n }", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "public int nextInt() {\n return Integer.parseInt(nextToken());\n }", "nextInt", "{\n return Integer.parseInt(nextToken());\n }", "return Integer.parseInt(nextToken());", "Integer.parseInt(nextToken())", "Integer.parseInt", "Integer", "nextToken()", "nextToken", "public long nextLong() {\n return Long.parseLong(nextToken());\n }", "nextLong", "{\n return Long.parseLong(nextToken());\n }", "return Long.parseLong(nextToken());", "Long.parseLong(nextToken())", "Long.parseLong", "Long", "nextToken()", "nextToken", "public double nextDouble() {\n return Double.parseDouble(nextToken());\n }", "nextDouble", "{\n return Double.parseDouble(nextToken());\n }", "return Double.parseDouble(nextToken());", "Double.parseDouble(nextToken())", "Double.parseDouble", "Double", "nextToken()", "nextToken", "public class Main {\n\n static long mod = ((long) (1E9 + 7));\n\n public static void main(String[] args) {\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }\n\n\n static void solve(FastScanner in, PrintWriter out) {\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }\n\n static class Parser {\n final private int BUFFER_SIZE = 1 << 16;\n private DataInputStream din;\n private byte[] buffer;\n private int bufferPointer, bytesRead;\n\n public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }\n\n public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }\n\n public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }\n\n private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }\n }\n\n\n static class FastScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public FastScanner() {\n init();\n }\n\n public FastScanner(String name) {\n init(name);\n }\n\n public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }\n\n private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }\n\n public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(nextToken());\n }\n\n\n public long nextLong() {\n return Long.parseLong(nextToken());\n }\n\n public double nextDouble() {\n return Double.parseDouble(nextToken());\n }\n\n }\n\n\n}", "public class Main {\n\n static long mod = ((long) (1E9 + 7));\n\n public static void main(String[] args) {\n// Parser scr = new Parser(System.in);\n FastScanner scr = new FastScanner();\n PrintWriter out = new PrintWriter(System.out, true);\n// int t = scr.nextInt();\n// while (t-- > 0)\n solve(scr, out);\n out.close();\n }\n\n\n static void solve(FastScanner in, PrintWriter out) {\n// int N = in.nextInt();\n// int M = in.nextInt();\n// int X = in.nextInt();\n// int[] a = new int[M];\n// for (int i = 0; i < N; i++) {\n// int C = in.nextInt();\n// a[i] = in.nextInt();\n//\n// }\n long A = in.nextLong();\n long B = in.nextLong();\n long C = in.nextLong();\n long K = in.nextLong();\n long S = 0;\n\n if (A <= K) {\n S += A;\n K -= A;\n\n } else {\n S += K;\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n\n if (B <= K) {\n K -= B;\n } else {\n K = 0;\n }\n if (K == 0) {\n out.println(S);\n return;\n }\n if (C <= K) {\n S -= C;\n } else {\n S -= K;\n }\n out.println(S);\n\n\n }\n\n static class Parser {\n final private int BUFFER_SIZE = 1 << 16;\n private DataInputStream din;\n private byte[] buffer;\n private int bufferPointer, bytesRead;\n\n public Parser(InputStream in) {\n din = new DataInputStream(in);\n buffer = new byte[BUFFER_SIZE];\n bufferPointer = bytesRead = 0;\n }\n\n public String nextString(int maxSize) {\n byte[] ch = new byte[maxSize];\n int point = 0;\n try {\n byte c = read();\n while (c == ' ' || c == '\\n' || c == '\\r')\n c = read();\n while (c != ' ' && c != '\\n' && c != '\\r') {\n ch[point++] = c;\n c = read();\n }\n } catch (Exception e) {\n }\n return new String(ch, 0, point);\n }\n\n public int nextInt() {\n int ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n public long nextLong() {\n long ret = 0;\n boolean neg;\n try {\n byte c = read();\n while (c <= ' ')\n c = read();\n neg = c == '-';\n if (neg)\n c = read();\n do {\n ret = ret * 10 + c - '0';\n c = read();\n } while (c > ' ');\n\n if (neg) return -ret;\n } catch (Exception e) {\n }\n return ret;\n }\n\n private void fillBuffer() {\n try {\n bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);\n } catch (Exception e) {\n }\n if (bytesRead == -1) buffer[0] = -1;\n }\n\n private byte read() {\n if (bufferPointer == bytesRead) fillBuffer();\n return buffer[bufferPointer++];\n }\n }\n\n\n static class FastScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public FastScanner() {\n init();\n }\n\n public FastScanner(String name) {\n init(name);\n }\n\n public FastScanner(boolean isOnlineJudge) {\n if (!isOnlineJudge || System.getProperty(\"ONLINE_JUDGE\") != null) {\n init();\n } else {\n init(\"input.txt\");\n }\n }\n\n private void init() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n private void init(String name) {\n try {\n br = new BufferedReader(new FileReader(name));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }\n\n public String nextToken() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n public int nextInt() {\n return Integer.parseInt(nextToken());\n }\n\n\n public long nextLong() {\n return Long.parseLong(nextToken());\n }\n\n public double nextDouble() {\n return Double.parseDouble(nextToken());\n }\n\n }\n\n\n}", "Main" ]
import java.io.*; import java.math.BigInteger; import java.util.*; public class Main { static long mod = ((long) (1E9 + 7)); public static void main(String[] args) { // Parser scr = new Parser(System.in); FastScanner scr = new FastScanner(); PrintWriter out = new PrintWriter(System.out, true); // int t = scr.nextInt(); // while (t-- > 0) solve(scr, out); out.close(); } static void solve(FastScanner in, PrintWriter out) { // int N = in.nextInt(); // int M = in.nextInt(); // int X = in.nextInt(); // int[] a = new int[M]; // for (int i = 0; i < N; i++) { // int C = in.nextInt(); // a[i] = in.nextInt(); // // } long A = in.nextLong(); long B = in.nextLong(); long C = in.nextLong(); long K = in.nextLong(); long S = 0; if (A <= K) { S += A; K -= A; } else { S += K; K = 0; } if (K == 0) { out.println(S); return; } if (B <= K) { K -= B; } else { K = 0; } if (K == 0) { out.println(S); return; } if (C <= K) { S -= C; } else { S -= K; } out.println(S); } static class Parser { final private int BUFFER_SIZE = 1 << 16; private DataInputStream din; private byte[] buffer; private int bufferPointer, bytesRead; public Parser(InputStream in) { din = new DataInputStream(in); buffer = new byte[BUFFER_SIZE]; bufferPointer = bytesRead = 0; } public String nextString(int maxSize) { byte[] ch = new byte[maxSize]; int point = 0; try { byte c = read(); while (c == ' ' || c == '\n' || c == '\r') c = read(); while (c != ' ' && c != '\n' && c != '\r') { ch[point++] = c; c = read(); } } catch (Exception e) { } return new String(ch, 0, point); } public int nextInt() { int ret = 0; boolean neg; try { byte c = read(); while (c <= ' ') c = read(); neg = c == '-'; if (neg) c = read(); do { ret = ret * 10 + c - '0'; c = read(); } while (c > ' '); if (neg) return -ret; } catch (Exception e) { } return ret; } public long nextLong() { long ret = 0; boolean neg; try { byte c = read(); while (c <= ' ') c = read(); neg = c == '-'; if (neg) c = read(); do { ret = ret * 10 + c - '0'; c = read(); } while (c > ' '); if (neg) return -ret; } catch (Exception e) { } return ret; } private void fillBuffer() { try { bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE); } catch (Exception e) { } if (bytesRead == -1) buffer[0] = -1; } private byte read() { if (bufferPointer == bytesRead) fillBuffer(); return buffer[bufferPointer++]; } } static class FastScanner { BufferedReader br; StringTokenizer st; public FastScanner() { init(); } public FastScanner(String name) { init(name); } public FastScanner(boolean isOnlineJudge) { if (!isOnlineJudge || System.getProperty("ONLINE_JUDGE") != null) { init(); } else { init("input.txt"); } } private void init() { br = new BufferedReader(new InputStreamReader(System.in)); } private void init(String name) { try { br = new BufferedReader(new FileReader(name)); } catch (FileNotFoundException e) { e.printStackTrace(); } } public String nextToken() { while (st == null || !st.hasMoreElements()) { try { st = new StringTokenizer(br.readLine()); } catch (IOException e) { e.printStackTrace(); } } return st.nextToken(); } public int nextInt() { return Integer.parseInt(nextToken()); } public long nextLong() { return Long.parseLong(nextToken()); } public double nextDouble() { return Double.parseDouble(nextToken()); } } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 20, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 72, 5 ], [ 72, 6 ], [ 6, 7 ], [ 6, 8 ], [ 72, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 11, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 11, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 11, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 11, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 32, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 50, 55 ], [ 43, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 57, 62 ], [ 62, 63 ], [ 62, 64 ], [ 64, 65 ], [ 65, 66 ], [ 65, 67 ], [ 64, 68 ], [ 9, 69 ], [ 69, 70 ], [ 0, 71 ], [ 71, 72 ], [ 71, 73 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n static Scanner stdIn = new Scanner(System.in);\n public static void main(String[] args){\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n static Scanner stdIn = new Scanner(System.in);\n public static void main(String[] args){\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }\n}", "Main", "static Scanner stdIn = new Scanner(System.in);", "stdIn", "new Scanner(System.in)", "public static void main(String[] args){\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }", "main", "{\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }", "long a = stdIn.nextLong();", "a", "stdIn.nextLong()", "stdIn.nextLong", "stdIn", "long b = stdIn.nextLong();", "b", "stdIn.nextLong()", "stdIn.nextLong", "stdIn", "long c = stdIn.nextLong();", "c", "stdIn.nextLong()", "stdIn.nextLong", "stdIn", "long k = stdIn.nextLong();", "k", "stdIn.nextLong()", "stdIn.nextLong", "stdIn", "if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }", "k <= a", "k", "a", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }", "k <= a + b", "k", "a + b", "a", "b", "{\n System.out.println(a);\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n System.out.println(a - (k - a - b));\n }", "System.out.println(a - (k - a - b))", "System.out.println", "System.out", "System", "System.out", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "String[] args", "args", "public class Main {\n static Scanner stdIn = new Scanner(System.in);\n public static void main(String[] args){\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }\n}", "public class Main {\n static Scanner stdIn = new Scanner(System.in);\n public static void main(String[] args){\n long a = stdIn.nextLong();\n long b = stdIn.nextLong();\n long c = stdIn.nextLong();\n long k = stdIn.nextLong();\n\n if(k <= a){\n System.out.println(k);\n }else if(k <= a + b){\n System.out.println(a);\n }else{\n System.out.println(a - (k - a - b));\n }\n }\n}", "Main" ]
import java.util.Scanner; public class Main { static Scanner stdIn = new Scanner(System.in); public static void main(String[] args){ long a = stdIn.nextLong(); long b = stdIn.nextLong(); long c = stdIn.nextLong(); long k = stdIn.nextLong(); if(k <= a){ System.out.println(k); }else if(k <= a + b){ System.out.println(a); }else{ System.out.println(a - (k - a - b)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 41, 13, 4, 18, 13, 13, 13, 0, 13, 13, 0, 13, 13, 0, 13, 2, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 13, 0, 13, 13, 0, 13, 4, 18, 13, 13, 13, 0, 13, 13, 0, 13, 13, 0, 13, 2, 13, 40, 17, 4, 18, 18, 13, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 12, 13, 30, 41, 13, 4, 13, 41, 13, 20, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 14, 2, 4, 18, 13, 17, 17, 30, 0, 13, 17, 40, 13, 11, 1, 41, 13, 13, 2, 13, 4, 18, 13, 1, 40, 13, 30, 14, 2, 4, 18, 13, 13, 17, 30, 0, 13, 4, 18, 13, 4, 18, 13, 0, 13, 20, 0, 13, 17, 30, 4, 18, 13, 4, 18, 13, 13, 14, 13, 0, 13, 17, 0, 13, 2, 4, 18, 13, 4, 18, 13, 13, 29, 2, 13, 8, 13, 40, 17, 17, 12, 13, 30, 29, 4, 18, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 276, 17 ], [ 276, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 21, 23 ], [ 20, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 20, 29 ], [ 29, 30 ], [ 29, 31 ], [ 31, 32 ], [ 32, 33 ], [ 20, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 37, 38 ], [ 20, 39 ], [ 39, 40 ], [ 39, 41 ], [ 41, 42 ], [ 42, 43 ], [ 20, 44 ], [ 44, 45 ], [ 44, 46 ], [ 20, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 50, 51 ], [ 49, 52 ], [ 49, 53 ], [ 20, 54 ], [ 54, 55 ], [ 54, 56 ], [ 20, 57 ], [ 57, 58 ], [ 57, 59 ], [ 20, 60 ], [ 60, 61 ], [ 60, 62 ], [ 62, 63 ], [ 62, 64 ], [ 20, 65 ], [ 65, 66 ], [ 65, 67 ], [ 67, 68 ], [ 68, 69 ], [ 67, 70 ], [ 67, 71 ], [ 20, 72 ], [ 72, 73 ], [ 72, 74 ], [ 20, 75 ], [ 75, 76 ], [ 75, 77 ], [ 20, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 81, 82 ], [ 80, 83 ], [ 80, 84 ], [ 20, 85 ], [ 85, 86 ], [ 85, 87 ], [ 20, 88 ], [ 88, 89 ], [ 88, 90 ], [ 20, 91 ], [ 91, 92 ], [ 91, 93 ], [ 93, 94 ], [ 93, 95 ], [ 95, 96 ], [ 20, 97 ], [ 97, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 97, 102 ], [ 18, 103 ], [ 103, 104 ], [ 0, 105 ], [ 105, 106 ], [ 105, 107 ], [ 107, 108 ], [ 105, 109 ], [ 109, 110 ], [ 105, 111 ], [ 111, 112 ], [ 111, 113 ], [ 113, 114 ], [ 114, 115 ], [ 114, 116 ], [ 111, 117 ], [ 117, 118 ], [ 105, 119 ], [ 119, 120 ], [ 119, 121 ], [ 121, 122 ], [ 122, 123 ], [ 123, 124 ], [ 124, 125 ], [ 124, 126 ], [ 123, 127 ], [ 127, 128 ], [ 128, 129 ], [ 129, 130 ], [ 122, 131 ], [ 131, 132 ], [ 131, 133 ], [ 121, 134 ], [ 134, 135 ], [ 135, 136 ], [ 136, 137 ], [ 105, 138 ], [ 138, 139 ], [ 138, 140 ], [ 140, 141 ], [ 141, 142 ], [ 142, 143 ], [ 143, 144 ], [ 142, 145 ], [ 145, 146 ], [ 105, 147 ], [ 147, 148 ], [ 147, 149 ], [ 149, 150 ], [ 150, 151 ], [ 151, 152 ], [ 152, 153 ], [ 151, 154 ], [ 154, 155 ], [ 105, 156 ], [ 156, 157 ], [ 156, 158 ], [ 158, 159 ], [ 159, 160 ], [ 160, 161 ], [ 161, 162 ], [ 105, 163 ], [ 163, 164 ], [ 163, 165 ], [ 165, 166 ], [ 166, 167 ], [ 166, 168 ], [ 168, 169 ], [ 165, 170 ], [ 170, 171 ], [ 170, 172 ], [ 165, 173 ], [ 173, 174 ], [ 173, 175 ], [ 165, 176 ], [ 176, 177 ], [ 176, 178 ], [ 165, 179 ], [ 179, 180 ], [ 179, 181 ], [ 165, 182 ], [ 182, 183 ], [ 182, 184 ], [ 165, 185 ], [ 185, 186 ], [ 185, 187 ], [ 165, 188 ], [ 188, 189 ], [ 189, 190 ], [ 190, 191 ], [ 191, 192 ], [ 190, 193 ], [ 189, 194 ], [ 188, 195 ], [ 195, 196 ], [ 196, 197 ], [ 196, 198 ], [ 195, 199 ], [ 199, 200 ], [ 165, 201 ], [ 201, 202 ], [ 202, 203 ], [ 203, 204 ], [ 203, 205 ], [ 201, 206 ], [ 206, 207 ], [ 206, 208 ], [ 208, 209 ], [ 209, 210 ], [ 201, 211 ], [ 211, 212 ], [ 212, 213 ], [ 201, 214 ], [ 214, 215 ], [ 215, 216 ], [ 216, 217 ], [ 217, 218 ], [ 218, 219 ], [ 217, 220 ], [ 216, 221 ], [ 215, 222 ], [ 222, 223 ], [ 223, 224 ], [ 223, 225 ], [ 225, 226 ], [ 226, 227 ], [ 225, 228 ], [ 228, 229 ], [ 229, 230 ], [ 222, 231 ], [ 231, 232 ], [ 231, 233 ], [ 222, 234 ], [ 234, 235 ], [ 234, 236 ], [ 215, 237 ], [ 237, 238 ], [ 238, 239 ], [ 239, 240 ], [ 238, 241 ], [ 241, 242 ], [ 242, 243 ], [ 241, 244 ], [ 237, 245 ], [ 245, 246 ], [ 245, 247 ], [ 247, 248 ], [ 247, 249 ], [ 165, 250 ], [ 250, 251 ], [ 250, 252 ], [ 252, 253 ], [ 253, 254 ], [ 254, 255 ], [ 253, 256 ], [ 256, 257 ], [ 257, 258 ], [ 252, 259 ], [ 165, 260 ], [ 260, 261 ], [ 261, 262 ], [ 261, 263 ], [ 263, 264 ], [ 263, 265 ], [ 265, 266 ], [ 263, 267 ], [ 105, 268 ], [ 268, 269 ], [ 268, 270 ], [ 270, 271 ], [ 271, 272 ], [ 272, 273 ], [ 273, 274 ], [ 0, 275 ], [ 275, 276 ], [ 275, 277 ] ]
[ "\nimport java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.InputStreamReader;\nimport java.util.*;\n\n\npublic class Main {\n\n public static void main(String[] args) throws IOException {\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }\n}\n\n\n\n\nclass Scanner\n{\n StringTokenizer st;\n BufferedReader br;\n\n public Scanner(InputStream s){\tbr = new BufferedReader(new InputStreamReader(s));}\n\n public String next() throws IOException\n {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {return Integer.parseInt(next());}\n\n public long nextLong() throws IOException {return Long.parseLong(next());}\n\n public String nextLine() throws IOException {return br.readLine();}\n\n public double nextDouble() throws IOException\n {\n String x = next();\n StringBuilder sb = new StringBuilder(\"0\");\n double res = 0, f = 1;\n boolean dec = false, neg = false;\n int start = 0;\n if(x.charAt(0) == '-')\n {\n neg = true;\n start++;\n }\n for(int i = start; i < x.length(); i++)\n if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }\n res += Long.parseLong(sb.toString()) / f;\n return res * (neg?-1:1);\n }\n\n public boolean ready() throws IOException {return br.ready();}\n\n\n}", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.util.*;", "util.*", "java", "public class Main {\n\n public static void main(String[] args) throws IOException {\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }\n}", "Main", "public static void main(String[] args) throws IOException {\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }", "main", "{\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }", "Scanner s = new Scanner(System.in);", "s", "new Scanner(System.in)", "int a =s.nextInt()", "a", "s.nextInt()", "s.nextInt", "s", "b=s.nextInt()", "b", "s.nextInt()", "s.nextInt", "s", "c=s.nextInt()", "c", "s.nextInt()", "s.nextInt", "s", "k=s.nextInt();", "k", "s.nextInt()", "s.nextInt", "s", "long sum=0;", "sum", "0", "int min = Math.min(a,k);", "min", "Math.min(a,k)", "Math.min", "Math", "a", "k", "a-=min", "a", "min", "k-=min", "k", "min", "sum += min*1", "sum", "min*1", "min", "1", "min = Math.min(b,k)", "min", "Math.min(b,k)", "Math.min", "Math", "b", "k", "b-=min", "b", "min", "k-=min", "k", "min", "min = Math.min(c,k)", "min", "Math.min(c,k)", "Math.min", "Math", "c", "k", "c-=min", "c", "min", "k-=min", "k", "min", "sum += (min*-1)", "sum", "(min*-1)", "min", "-1", "1", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "class Scanner\n{\n StringTokenizer st;\n BufferedReader br;\n\n public Scanner(InputStream s){\tbr = new BufferedReader(new InputStreamReader(s));}\n\n public String next() throws IOException\n {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }\n\n public int nextInt() throws IOException {return Integer.parseInt(next());}\n\n public long nextLong() throws IOException {return Long.parseLong(next());}\n\n public String nextLine() throws IOException {return br.readLine();}\n\n public double nextDouble() throws IOException\n {\n String x = next();\n StringBuilder sb = new StringBuilder(\"0\");\n double res = 0, f = 1;\n boolean dec = false, neg = false;\n int start = 0;\n if(x.charAt(0) == '-')\n {\n neg = true;\n start++;\n }\n for(int i = start; i < x.length(); i++)\n if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }\n res += Long.parseLong(sb.toString()) / f;\n return res * (neg?-1:1);\n }\n\n public boolean ready() throws IOException {return br.ready();}\n\n\n}", "Scanner", "StringTokenizer st;", "st", "BufferedReader br;", "br", "public Scanner(InputStream s){\tbr = new BufferedReader(new InputStreamReader(s));}", "Scanner", "{\tbr = new BufferedReader(new InputStreamReader(s));}", "br = new BufferedReader(new InputStreamReader(s))", "br", "new BufferedReader(new InputStreamReader(s))", "InputStream s", "s", "public String next() throws IOException\n {\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());\n return st.nextToken();\n }", "while (st == null || !st.hasMoreTokens())\n st = new StringTokenizer(br.readLine());", "st == null || !st.hasMoreTokens()", "st == null", "st", "null", "!st.hasMoreTokens()", "st.hasMoreTokens()", "st.hasMoreTokens", "st", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "public int nextInt() throws IOException {return Integer.parseInt(next());}", "nextInt", "{return Integer.parseInt(next());}", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "public long nextLong() throws IOException {return Long.parseLong(next());}", "nextLong", "{return Long.parseLong(next());}", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "public String nextLine() throws IOException {return br.readLine();}", "nextLine", "{return br.readLine();}", "return br.readLine();", "br.readLine()", "br.readLine", "br", "public double nextDouble() throws IOException\n {\n String x = next();\n StringBuilder sb = new StringBuilder(\"0\");\n double res = 0, f = 1;\n boolean dec = false, neg = false;\n int start = 0;\n if(x.charAt(0) == '-')\n {\n neg = true;\n start++;\n }\n for(int i = start; i < x.length(); i++)\n if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }\n res += Long.parseLong(sb.toString()) / f;\n return res * (neg?-1:1);\n }", "nextDouble", "{\n String x = next();\n StringBuilder sb = new StringBuilder(\"0\");\n double res = 0, f = 1;\n boolean dec = false, neg = false;\n int start = 0;\n if(x.charAt(0) == '-')\n {\n neg = true;\n start++;\n }\n for(int i = start; i < x.length(); i++)\n if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }\n res += Long.parseLong(sb.toString()) / f;\n return res * (neg?-1:1);\n }", "String x = next();", "x", "next()", "next", "StringBuilder sb = new StringBuilder(\"0\");", "sb", "new StringBuilder(\"0\")", "double res = 0", "res", "0", "f = 1;", "f", "1", "boolean dec = false", "dec", "false", "neg = false;", "neg", "false", "int start = 0;", "start", "0", "if(x.charAt(0) == '-')\n {\n neg = true;\n start++;\n }", "x.charAt(0) == '-'", "x.charAt(0)", "x.charAt", "x", "0", "'-'", "{\n neg = true;\n start++;\n }", "neg = true", "neg", "true", "start++", "start", "for(int i = start; i < x.length(); i++)\n if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }", "int i = start;", "int i = start;", "i", "start", "i < x.length()", "i", "x.length()", "x.length", "x", "i++", "i++", "i", "if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }", "if(x.charAt(i) == '.')\n {\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }\n else\n {\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }", "x.charAt(i) == '.'", "x.charAt(i)", "x.charAt", "x", "i", "'.'", "{\n res = Long.parseLong(sb.toString());\n sb = new StringBuilder(\"0\");\n dec = true;\n }", "res = Long.parseLong(sb.toString())", "res", "Long.parseLong(sb.toString())", "Long.parseLong", "Long", "sb.toString()", "sb.toString", "sb", "sb = new StringBuilder(\"0\")", "sb", "new StringBuilder(\"0\")", "dec = true", "dec", "true", "{\n sb.append(x.charAt(i));\n if(dec)\n f *= 10;\n }", "sb.append(x.charAt(i))", "sb.append", "sb", "x.charAt(i)", "x.charAt", "x", "i", "if(dec)\n f *= 10;", "dec", "f *= 10", "f", "10", "res += Long.parseLong(sb.toString()) / f", "res", "Long.parseLong(sb.toString()) / f", "Long.parseLong(sb.toString())", "Long.parseLong", "Long", "sb.toString()", "sb.toString", "sb", "f", "return res * (neg?-1:1);", "res * (neg?-1:1)", "res", "(neg?-1:1)", "neg", "-1", "1", "1", "public boolean ready() throws IOException {return br.ready();}", "ready", "{return br.ready();}", "return br.ready();", "br.ready()", "br.ready", "br", "public class Main {\n\n public static void main(String[] args) throws IOException {\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }\n}", "public class Main {\n\n public static void main(String[] args) throws IOException {\n Scanner s = new Scanner(System.in);\n int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt();\n long sum=0;\n int min = Math.min(a,k);\n a-=min;k-=min;\n sum += min*1;\n min = Math.min(b,k);\n b-=min;k-=min;\n\n min = Math.min(c,k);\n c-=min;k-=min;\n sum += (min*-1);\n System.out.println(sum);\n }\n}", "Main" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.util.*; public class Main { public static void main(String[] args) throws IOException { Scanner s = new Scanner(System.in); int a =s.nextInt(),b=s.nextInt(),c=s.nextInt(),k=s.nextInt(); long sum=0; int min = Math.min(a,k); a-=min;k-=min; sum += min*1; min = Math.min(b,k); b-=min;k-=min; min = Math.min(c,k); c-=min;k-=min; sum += (min*-1); System.out.println(sum); } } class Scanner { StringTokenizer st; BufferedReader br; public Scanner(InputStream s){ br = new BufferedReader(new InputStreamReader(s));} public String next() throws IOException { while (st == null || !st.hasMoreTokens()) st = new StringTokenizer(br.readLine()); return st.nextToken(); } public int nextInt() throws IOException {return Integer.parseInt(next());} public long nextLong() throws IOException {return Long.parseLong(next());} public String nextLine() throws IOException {return br.readLine();} public double nextDouble() throws IOException { String x = next(); StringBuilder sb = new StringBuilder("0"); double res = 0, f = 1; boolean dec = false, neg = false; int start = 0; if(x.charAt(0) == '-') { neg = true; start++; } for(int i = start; i < x.length(); i++) if(x.charAt(i) == '.') { res = Long.parseLong(sb.toString()); sb = new StringBuilder("0"); dec = true; } else { sb.append(x.charAt(i)); if(dec) f *= 10; } res += Long.parseLong(sb.toString()) / f; return res * (neg?-1:1); } public boolean ready() throws IOException {return br.ready();} }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 13, 41, 13, 17, 14, 2, 2, 13, 13, 13, 30, 0, 13, 2, 13, 2, 13, 13, 0, 13, 2, 13, 13, 14, 2, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 74, 5 ], [ 74, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 8, 38 ], [ 38, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 38, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 49, 51 ], [ 44, 52 ], [ 52, 53 ], [ 52, 54 ], [ 54, 55 ], [ 54, 56 ], [ 38, 57 ], [ 57, 58 ], [ 58, 59 ], [ 58, 60 ], [ 57, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 8, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 65, 70 ], [ 6, 71 ], [ 71, 72 ], [ 0, 73 ], [ 73, 74 ], [ 73, 75 ] ]
[ "import java.util.Scanner;\n \npublic class Main{\n public static void main(String[] args) {\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main{\n public static void main(String[] args) {\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }", "main", "{\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }", "Scanner in=new Scanner(System.in);", "in", "new Scanner(System.in)", "int a=in.nextInt();", "a", "in.nextInt()", "in.nextInt", "in", "int b=in.nextInt();", "b", "in.nextInt()", "in.nextInt", "in", "int c=in.nextInt();", "c", "in.nextInt()", "in.nextInt", "in", "int k=in.nextInt();", "k", "in.nextInt()", "in.nextInt", "in", "int sum=a", "sum", "a", "min=0;", "min", "0", "if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }", "(a+b)<=k", "(a+b)", "a", "b", "k", "{\n min=k-(a+b);\n sum=sum-min;\n }", "min=k-(a+b)", "min", "k-(a+b)", "k", "(a+b)", "a", "b", "sum=sum-min", "sum", "sum-min", "sum", "min", "if(a>k){\n sum=k;\n }", "a>k", "a", "k", "{\n sum=k;\n }", "sum=k", "sum", "k", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main{\n public static void main(String[] args) {\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }\n}", "public class Main{\n public static void main(String[] args) {\n Scanner in=new Scanner(System.in);\n int a=in.nextInt();\n int b=in.nextInt();\n int c=in.nextInt();\n int k=in.nextInt();\n int sum=a,min=0;\n if((a+b)<=k){\n min=k-(a+b);\n sum=sum-min;\n }else if(a>k){\n sum=k;\n }\n System.out.println(sum);\n }\n}", "Main" ]
import java.util.Scanner; public class Main{ public static void main(String[] args) { Scanner in=new Scanner(System.in); int a=in.nextInt(); int b=in.nextInt(); int c=in.nextInt(); int k=in.nextInt(); int sum=a,min=0; if((a+b)<=k){ min=k-(a+b); sum=sum-min; }else if(a>k){ sum=k; } System.out.println(sum); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 17, 12, 13, 30, 14, 2, 13, 17, 29, 13, 29, 4, 13, 2, 13, 13, 13, 23, 13, 23, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 0, 13, 2, 4, 18, 13, 13, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 4, 18, 13, 13, 13, 17, 0, 13, 4, 18, 13, 13, 13, 0, 13, 2, 4, 18, 13, 13, 13, 40, 17, 0, 13, 4, 18, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 17, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 4, 18, 13, 29, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 219, 20 ], [ 219, 21 ], [ 21, 22 ], [ 21, 23 ], [ 219, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 28, 29 ], [ 28, 30 ], [ 27, 31 ], [ 31, 32 ], [ 26, 33 ], [ 33, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 36, 38 ], [ 34, 39 ], [ 24, 40 ], [ 40, 41 ], [ 24, 42 ], [ 42, 43 ], [ 219, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 50, 52 ], [ 52, 53 ], [ 53, 54 ], [ 46, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 58, 59 ], [ 46, 60 ], [ 60, 61 ], [ 60, 62 ], [ 62, 63 ], [ 63, 64 ], [ 46, 65 ], [ 65, 66 ], [ 65, 67 ], [ 67, 68 ], [ 68, 69 ], [ 46, 70 ], [ 70, 71 ], [ 70, 72 ], [ 46, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 76, 77 ], [ 77, 78 ], [ 76, 79 ], [ 76, 80 ], [ 75, 81 ], [ 46, 82 ], [ 82, 83 ], [ 82, 84 ], [ 84, 85 ], [ 85, 86 ], [ 84, 87 ], [ 84, 88 ], [ 46, 89 ], [ 89, 90 ], [ 89, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 92, 95 ], [ 92, 96 ], [ 91, 97 ], [ 46, 98 ], [ 98, 99 ], [ 98, 100 ], [ 100, 101 ], [ 101, 102 ], [ 100, 103 ], [ 100, 104 ], [ 46, 105 ], [ 105, 106 ], [ 105, 107 ], [ 107, 108 ], [ 108, 109 ], [ 109, 110 ], [ 108, 111 ], [ 108, 112 ], [ 107, 113 ], [ 113, 114 ], [ 46, 115 ], [ 115, 116 ], [ 115, 117 ], [ 117, 118 ], [ 118, 119 ], [ 117, 120 ], [ 117, 121 ], [ 46, 122 ], [ 122, 123 ], [ 123, 124 ], [ 124, 125 ], [ 124, 126 ], [ 122, 127 ], [ 44, 128 ], [ 128, 129 ], [ 219, 130 ], [ 130, 131 ], [ 130, 132 ], [ 132, 133 ], [ 130, 134 ], [ 134, 135 ], [ 130, 136 ], [ 136, 137 ], [ 136, 138 ], [ 138, 139 ], [ 139, 140 ], [ 139, 141 ], [ 130, 142 ], [ 142, 143 ], [ 142, 144 ], [ 144, 145 ], [ 145, 146 ], [ 146, 147 ], [ 147, 148 ], [ 147, 149 ], [ 146, 150 ], [ 150, 151 ], [ 151, 152 ], [ 152, 153 ], [ 145, 154 ], [ 154, 155 ], [ 155, 156 ], [ 156, 157 ], [ 156, 158 ], [ 158, 159 ], [ 159, 160 ], [ 160, 161 ], [ 155, 162 ], [ 162, 163 ], [ 163, 164 ], [ 163, 165 ], [ 144, 166 ], [ 166, 167 ], [ 167, 168 ], [ 168, 169 ], [ 130, 170 ], [ 170, 171 ], [ 170, 172 ], [ 172, 173 ], [ 173, 174 ], [ 174, 175 ], [ 175, 176 ], [ 174, 177 ], [ 177, 178 ], [ 130, 179 ], [ 179, 180 ], [ 179, 181 ], [ 181, 182 ], [ 182, 183 ], [ 183, 184 ], [ 184, 185 ], [ 183, 186 ], [ 186, 187 ], [ 130, 188 ], [ 188, 189 ], [ 188, 190 ], [ 190, 191 ], [ 191, 192 ], [ 192, 193 ], [ 193, 194 ], [ 192, 195 ], [ 195, 196 ], [ 130, 197 ], [ 197, 198 ], [ 197, 199 ], [ 199, 200 ], [ 200, 201 ], [ 200, 202 ], [ 199, 203 ], [ 203, 204 ], [ 204, 205 ], [ 204, 206 ], [ 206, 207 ], [ 207, 208 ], [ 208, 209 ], [ 203, 210 ], [ 210, 211 ], [ 211, 212 ], [ 211, 213 ], [ 213, 214 ], [ 214, 215 ], [ 199, 216 ], [ 216, 217 ], [ 0, 218 ], [ 218, 219 ], [ 218, 220 ] ]
[ "import javax.print.attribute.HashAttributeSet;\nimport java.io.*;\n\nimport java.math.BigInteger;\nimport java.util.*;\n\nimport java.util.ArrayList;\n\nimport java.util.Scanner;\n\n\npublic class Main {\n\n static class FastReader {\n BufferedReader br;\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n\n static final int mod = 1000000007;\n\n public static int gcd(int a, int b)\n {\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }\n\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }\n}\n\n\n\n\n\n\n", "import javax.print.attribute.HashAttributeSet;", "HashAttributeSet", "javax.print.attribute", "import java.io.*;", "io.*", "java", "import java.math.BigInteger;", "BigInteger", "java.math", "import java.util.*;", "util.*", "java", "import java.util.ArrayList;", "ArrayList", "java.util", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n static class FastReader {\n BufferedReader br;\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n\n static final int mod = 1000000007;\n\n public static int gcd(int a, int b)\n {\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }\n\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }\n}", "Main", "static final int mod = 1000000007;", "mod", "1000000007", "public static int gcd(int a, int b)\n {\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }", "gcd", "{\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }", "if (a == 0)\n return b;", "a == 0", "a", "0", "return b;", "b", "return gcd(b % a, a);", "gcd(b % a, a)", "gcd", "b % a", "b", "a", "a", "int a", "a", "int b", "b", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a=sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b=sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c=sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k=sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int ans=0;", "ans", "0", "ans+=Math.min(a,k)*1", "ans", "Math.min(a,k)*1", "Math.min(a,k)", "Math.min", "Math", "a", "k", "1", "k-=Math.min(k,a)", "k", "Math.min(k,a)", "Math.min", "Math", "k", "a", "ans+=Math.min(b,k)*0", "ans", "Math.min(b,k)*0", "Math.min(b,k)", "Math.min", "Math", "b", "k", "0", "k-=Math.min(k,b)", "k", "Math.min(k,b)", "Math.min", "Math", "k", "b", "ans+=Math.min(c,k)*(-1)", "ans", "Math.min(c,k)*(-1)", "Math.min(c,k)", "Math.min", "Math", "c", "k", "(-1)", "1", "k-=Math.min(k,c)", "k", "Math.min(k,c)", "Math.min", "Math", "k", "c", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "String[] args", "args", "static class FastReader {\n BufferedReader br;\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }", "FastReader", "BufferedReader br;", "br", "StringTokenizer st;", "st", "public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }", "FastReader", "{\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }", "br = new BufferedReader(new\n InputStreamReader(System.in))", "br", "new BufferedReader(new\n InputStreamReader(System.in))", "String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "st == null || !st.hasMoreElements()", "st == null", "st", "null", "!st.hasMoreElements()", "st.hasMoreElements()", "st.hasMoreElements", "st", "{\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n st = new StringTokenizer(br.readLine());\n }", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "int nextInt() {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "long nextLong() {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "double nextDouble() {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "nextLine", "{\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "String str = \"\";", "str", "\"\"", "try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n str = br.readLine();\n }", "str = br.readLine()", "str", "br.readLine()", "br.readLine", "br", "return str;", "str", "public class Main {\n\n static class FastReader {\n BufferedReader br;\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n\n static final int mod = 1000000007;\n\n public static int gcd(int a, int b)\n {\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }\n\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }\n}", "public class Main {\n\n static class FastReader {\n BufferedReader br;\n StringTokenizer st;\n\n public FastReader() {\n br = new BufferedReader(new\n InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine() {\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n }\n\n static final int mod = 1000000007;\n\n public static int gcd(int a, int b)\n {\n if (a == 0)\n return b;\n return gcd(b % a, a);\n }\n\n\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int a=sc.nextInt();\n int b=sc.nextInt();\n int c=sc.nextInt();\n int k=sc.nextInt();\n int ans=0;\n ans+=Math.min(a,k)*1;\n k-=Math.min(k,a);\n ans+=Math.min(b,k)*0;\n k-=Math.min(k,b);\n ans+=Math.min(c,k)*(-1);\n k-=Math.min(k,c);\n System.out.println(ans);\n\n\n\n\n }\n}", "Main" ]
import javax.print.attribute.HashAttributeSet; import java.io.*; import java.math.BigInteger; import java.util.*; import java.util.ArrayList; import java.util.Scanner; public class Main { static class FastReader { BufferedReader br; StringTokenizer st; public FastReader() { br = new BufferedReader(new InputStreamReader(System.in)); } String next() { while (st == null || !st.hasMoreElements()) { try { st = new StringTokenizer(br.readLine()); } catch (IOException e) { e.printStackTrace(); } } return st.nextToken(); } int nextInt() { return Integer.parseInt(next()); } long nextLong() { return Long.parseLong(next()); } double nextDouble() { return Double.parseDouble(next()); } String nextLine() { String str = ""; try { str = br.readLine(); } catch (IOException e) { e.printStackTrace(); } return str; } } static final int mod = 1000000007; public static int gcd(int a, int b) { if (a == 0) return b; return gcd(b % a, a); } public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a=sc.nextInt(); int b=sc.nextInt(); int c=sc.nextInt(); int k=sc.nextInt(); int ans=0; ans+=Math.min(a,k)*1; k-=Math.min(k,a); ans+=Math.min(b,k)*0; k-=Math.min(k,b); ans+=Math.min(c,k)*(-1); k-=Math.min(k,c); System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 2, 13, 13, 17, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 2, 13, 13, 17, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 2, 13, 2, 40, 17, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 86, 5 ], [ 86, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 36, 40 ], [ 35, 41 ], [ 41, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 42, 47 ], [ 35, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 48, 52 ], [ 52, 53 ], [ 52, 54 ], [ 48, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 55, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 55, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 72, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 72, 77 ], [ 77, 78 ], [ 77, 79 ], [ 79, 80 ], [ 80, 81 ], [ 79, 82 ], [ 6, 83 ], [ 83, 84 ], [ 0, 85 ], [ 85, 86 ], [ 85, 87 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int res = 0;", "res", "0", "if (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}", "k - a <= 0", "k - a", "k", "a", "0", "{\n\t\t\tSystem.out.println(k);\n\t\t}", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "{\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}", "res += a", "res", "a", "k -= a", "k", "a", "if (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}", "k - b <= 0", "k - b", "k", "b", "0", "{\n\t\t\t\tSystem.out.println(res);\n\t\t\t}", "System.out.println(res)", "System.out.println", "System.out", "System", "System.out", "res", "{\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}", "k -= b", "k", "b", "System.out.println(res + -1 * k)", "System.out.println", "System.out", "System", "System.out", "res + -1 * k", "res", "-1 * k", "-1", "1", "k", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint res = 0;\n\t\tif (k - a <= 0) {\n\t\t\tSystem.out.println(k);\n\t\t} else {\n\t\t\tres += a;\n\t\t\tk -= a;\n\t\t\tif (k - b <= 0) {\n\t\t\t\tSystem.out.println(res);\n\t\t\t} else {\n\t\t\t\tk -= b;\n\t\t\t\tSystem.out.println(res + -1 * k);\n\t\t\t}\n\t\t}\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int res = 0; if (k - a <= 0) { System.out.println(k); } else { res += a; k -= a; if (k - b <= 0) { System.out.println(res); } else { k -= b; System.out.println(res + -1 * k); } } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 17, 0, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 17, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 17, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 40, 17, 0, 13, 13, 14, 2, 2, 13, 17, 2, 13, 13, 30, 0, 13, 2, 13, 40, 17, 0, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 36, 40 ], [ 40, 41 ], [ 40, 42 ], [ 35, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 43, 49 ], [ 49, 50 ], [ 49, 51 ], [ 35, 52 ], [ 52, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 57, 58 ], [ 57, 59 ], [ 52, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 63, 65 ], [ 60, 66 ], [ 66, 67 ], [ 66, 68 ], [ 8, 69 ], [ 69, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 74, 75 ], [ 74, 76 ], [ 69, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 69, 81 ], [ 81, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 82, 86 ], [ 86, 87 ], [ 86, 88 ], [ 81, 89 ], [ 89, 90 ], [ 90, 91 ], [ 90, 92 ], [ 8, 93 ], [ 93, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 98, 100 ], [ 93, 101 ], [ 101, 102 ], [ 102, 103 ], [ 102, 104 ], [ 104, 105 ], [ 104, 106 ], [ 106, 107 ], [ 101, 108 ], [ 108, 109 ], [ 108, 110 ], [ 93, 111 ], [ 111, 112 ], [ 112, 113 ], [ 113, 114 ], [ 113, 115 ], [ 112, 116 ], [ 116, 117 ], [ 116, 118 ], [ 111, 119 ], [ 119, 120 ], [ 120, 121 ], [ 120, 122 ], [ 122, 123 ], [ 122, 124 ], [ 124, 125 ], [ 119, 126 ], [ 126, 127 ], [ 126, 128 ], [ 8, 129 ], [ 129, 130 ], [ 130, 131 ], [ 131, 132 ], [ 131, 133 ], [ 129, 134 ], [ 6, 135 ], [ 135, 136 ] ]
[ "import java.util.Scanner;\n \nclass Main {\n\tpublic static void main(String[] args) {\n \n\t Scanner sc = new Scanner(System.in);\n\t long A = sc.nextLong();\n\t long B = sc.nextLong();\n\t long C = sc.nextLong();\n\t long K = sc.nextLong();\n\t long max = 0;\n\t \n\t if (K > 0 && K >= A) {\n\t max += (A * 1);\n\t K -= A;\n\t } else if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }\n\t \n\t if (K > 0 && K >= B) {\n\t K -= B;\n\t } else if (K > 0 && K < B) {\n\t K = 0;\n\t }\n\t \n\t if(K > 0 && K >= C) {\n\t max += (C * -1);\n\t K -= C;\n\t } else if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }\n\t \n\t System.out.println(max);\n\t \n\t }\n}", "import java.util.Scanner;", "Scanner", "java.util", "class Main {\n\tpublic static void main(String[] args) {\n \n\t Scanner sc = new Scanner(System.in);\n\t long A = sc.nextLong();\n\t long B = sc.nextLong();\n\t long C = sc.nextLong();\n\t long K = sc.nextLong();\n\t long max = 0;\n\t \n\t if (K > 0 && K >= A) {\n\t max += (A * 1);\n\t K -= A;\n\t } else if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }\n\t \n\t if (K > 0 && K >= B) {\n\t K -= B;\n\t } else if (K > 0 && K < B) {\n\t K = 0;\n\t }\n\t \n\t if(K > 0 && K >= C) {\n\t max += (C * -1);\n\t K -= C;\n\t } else if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }\n\t \n\t System.out.println(max);\n\t \n\t }\n}", "Main", "public static void main(String[] args) {\n \n\t Scanner sc = new Scanner(System.in);\n\t long A = sc.nextLong();\n\t long B = sc.nextLong();\n\t long C = sc.nextLong();\n\t long K = sc.nextLong();\n\t long max = 0;\n\t \n\t if (K > 0 && K >= A) {\n\t max += (A * 1);\n\t K -= A;\n\t } else if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }\n\t \n\t if (K > 0 && K >= B) {\n\t K -= B;\n\t } else if (K > 0 && K < B) {\n\t K = 0;\n\t }\n\t \n\t if(K > 0 && K >= C) {\n\t max += (C * -1);\n\t K -= C;\n\t } else if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }\n\t \n\t System.out.println(max);\n\t \n\t }", "main", "{\n \n\t Scanner sc = new Scanner(System.in);\n\t long A = sc.nextLong();\n\t long B = sc.nextLong();\n\t long C = sc.nextLong();\n\t long K = sc.nextLong();\n\t long max = 0;\n\t \n\t if (K > 0 && K >= A) {\n\t max += (A * 1);\n\t K -= A;\n\t } else if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }\n\t \n\t if (K > 0 && K >= B) {\n\t K -= B;\n\t } else if (K > 0 && K < B) {\n\t K = 0;\n\t }\n\t \n\t if(K > 0 && K >= C) {\n\t max += (C * -1);\n\t K -= C;\n\t } else if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }\n\t \n\t System.out.println(max);\n\t \n\t }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "long A = sc.nextLong();", "A", "sc.nextLong()", "sc.nextLong", "sc", "long B = sc.nextLong();", "B", "sc.nextLong()", "sc.nextLong", "sc", "long C = sc.nextLong();", "C", "sc.nextLong()", "sc.nextLong", "sc", "long K = sc.nextLong();", "K", "sc.nextLong()", "sc.nextLong", "sc", "long max = 0;", "max", "0", "if (K > 0 && K >= A) {\n\t max += (A * 1);\n\t K -= A;\n\t } else if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }", "K > 0 && K >= A", "K > 0", "K", "0", "K >= A", "K", "A", "{\n\t max += (A * 1);\n\t K -= A;\n\t }", "max += (A * 1)", "max", "(A * 1)", "A", "1", "K -= A", "K", "A", "if (K > 0 && K < A) {\n\t max += (K * 1);\n\t K = 0;\n\t }", "K > 0 && K < A", "K > 0", "K", "0", "K < A", "K", "A", "{\n\t max += (K * 1);\n\t K = 0;\n\t }", "max += (K * 1)", "max", "(K * 1)", "K", "1", "K = 0", "K", "0", "if (K > 0 && K >= B) {\n\t K -= B;\n\t } else if (K > 0 && K < B) {\n\t K = 0;\n\t }", "K > 0 && K >= B", "K > 0", "K", "0", "K >= B", "K", "B", "{\n\t K -= B;\n\t }", "K -= B", "K", "B", "if (K > 0 && K < B) {\n\t K = 0;\n\t }", "K > 0 && K < B", "K > 0", "K", "0", "K < B", "K", "B", "{\n\t K = 0;\n\t }", "K = 0", "K", "0", "if(K > 0 && K >= C) {\n\t max += (C * -1);\n\t K -= C;\n\t } else if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }", "K > 0 && K >= C", "K > 0", "K", "0", "K >= C", "K", "C", "{\n\t max += (C * -1);\n\t K -= C;\n\t }", "max += (C * -1)", "max", "(C * -1)", "C", "-1", "1", "K -= C", "K", "C", "if (K > 0 && K < C) {\n\t max += (K * -1);\n\t K = 0;\n\t }", "K > 0 && K < C", "K > 0", "K", "0", "K < C", "K", "C", "{\n\t max += (K * -1);\n\t K = 0;\n\t }", "max += (K * -1)", "max", "(K * -1)", "K", "-1", "1", "K = 0", "K", "0", "System.out.println(max)", "System.out.println", "System.out", "System", "System.out", "max", "String[] args", "args" ]
import java.util.Scanner; class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); long A = sc.nextLong(); long B = sc.nextLong(); long C = sc.nextLong(); long K = sc.nextLong(); long max = 0; if (K > 0 && K >= A) { max += (A * 1); K -= A; } else if (K > 0 && K < A) { max += (K * 1); K = 0; } if (K > 0 && K >= B) { K -= B; } else if (K > 0 && K < B) { K = 0; } if(K > 0 && K >= C) { max += (C * -1); K -= C; } else if (K > 0 && K < C) { max += (K * -1); K = 0; } System.out.println(max); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 2, 40, 17, 2, 2, 13, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 74, 5 ], [ 74, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 8, 34 ], [ 34, 35 ], [ 35, 36 ], [ 35, 37 ], [ 34, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 34, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 45, 47 ], [ 42, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 42, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 56, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 59, 63 ], [ 55, 64 ], [ 8, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 65, 70 ], [ 6, 71 ], [ 71, 72 ], [ 0, 73 ], [ 73, 74 ], [ 73, 75 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }\n}", "Main", "public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }", "main", "{\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }", "Scanner scanner = new Scanner(System.in);", "scanner", "new Scanner(System.in)", "long A = scanner.nextLong();", "A", "scanner.nextLong()", "scanner.nextLong", "scanner", "long B = scanner.nextLong();", "B", "scanner.nextLong()", "scanner.nextLong", "scanner", "long C = scanner.nextLong();", "C", "scanner.nextLong()", "scanner.nextLong", "scanner", "long K = scanner.nextLong();", "K", "scanner.nextLong()", "scanner.nextLong", "scanner", "long result;", "result", "if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }", "A >= K", "A", "K", "{\n result = K;\n }", "result = K", "result", "K", "if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }", "B >= K - A", "B", "K - A", "K", "A", "{\n result = A;\n }", "result = A", "result", "A", "{\n result = -1 * (K - A - B) + A;\n }", "result = -1 * (K - A - B) + A", "result", "-1 * (K - A - B) + A", "-1 * (K - A - B)", "-1", "1", "(K - A - B)", "K - A - B", "K", "A", "B", "A", "System.out.println(result)", "System.out.println", "System.out", "System", "System.out", "result", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n long A = scanner.nextLong();\n long B = scanner.nextLong();\n long C = scanner.nextLong();\n\n long K = scanner.nextLong();\n\n long result;\n\n if (A >= K) {\n result = K;\n }\n else if (B >= K - A) {\n result = A;\n } else {\n result = -1 * (K - A - B) + A;\n }\n\n System.out.println(result);\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); long A = scanner.nextLong(); long B = scanner.nextLong(); long C = scanner.nextLong(); long K = scanner.nextLong(); long result; if (A >= K) { result = K; } else if (B >= K - A) { result = A; } else { result = -1 * (K - A - B) + A; } System.out.println(result); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 41, 13, 2, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 14, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 0, 13, 13, 4, 18, 18, 13, 13, 2, 13, 2, 13, 40, 17, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 84, 5 ], [ 84, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 39, 40 ], [ 39, 41 ], [ 36, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 42, 47 ], [ 47, 48 ], [ 47, 49 ], [ 32, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 51, 55 ], [ 50, 56 ], [ 56, 57 ], [ 57, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 57, 62 ], [ 50, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 63, 67 ], [ 67, 68 ], [ 67, 69 ], [ 63, 70 ], [ 70, 71 ], [ 71, 72 ], [ 72, 73 ], [ 72, 74 ], [ 70, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 77, 79 ], [ 79, 80 ], [ 6, 81 ], [ 81, 82 ], [ 0, 83 ], [ 83, 84 ], [ 83, 85 ] ]
[ "import java.util.*;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}\n}", "Main", "public static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a=sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b=sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c=sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k=sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}", "a>=k", "a", "k", "{\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}", "int n=a-k;", "n", "a-k", "a", "k", "System.out.println(a-n)", "System.out.println", "System.out", "System", "System.out", "a-n", "a", "n", "if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}", "a+b>=k", "a+b", "a", "b", "k", "{\n\t\t\tSystem.out.println(a);\n\t\t}", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}", "k-=a", "k", "a", "k-=b", "k", "b", "System.out.println(a+(k*(-1)))", "System.out.println", "System.out", "System", "System.out", "a+(k*(-1))", "a", "(k*(-1))", "k", "(-1)", "1", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint a=sc.nextInt();\n\t\tint b=sc.nextInt();\n\t\tint c=sc.nextInt();\n\t\tint k=sc.nextInt();\n\t\t\n\t\tif(a>=k){\n\t\t\tint n=a-k;\n\t\t\tSystem.out.println(a-n);\n\t\t}\n\t\telse if(a+b>=k){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\telse {\n\t\t\tk-=a;\n\t\t\tk-=b;\n\t\t\tSystem.out.println(a+(k*(-1)));\n\t\t}\n\t\t\n\t}\n}", "Main" ]
import java.util.*; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a=sc.nextInt(); int b=sc.nextInt(); int c=sc.nextInt(); int k=sc.nextInt(); if(a>=k){ int n=a-k; System.out.println(a-n); } else if(a+b>=k){ System.out.println(a); } else { k-=a; k-=b; System.out.println(a+(k*(-1))); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 12, 13, 30, 0, 13, 20, 12, 13, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 41, 13, 17, 38, 5, 13, 30, 4, 18, 13, 30, 0, 13, 4, 18, 13, 29, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 169, 8 ], [ 169, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 11, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 11, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 11, 35 ], [ 35, 36 ], [ 35, 37 ], [ 11, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 38, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 43, 48 ], [ 38, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 49, 53 ], [ 53, 54 ], [ 53, 55 ], [ 49, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 56, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 56, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 75, 77 ], [ 9, 78 ], [ 78, 79 ], [ 169, 80 ], [ 80, 81 ], [ 80, 82 ], [ 82, 83 ], [ 80, 84 ], [ 84, 85 ], [ 80, 86 ], [ 86, 87 ], [ 86, 88 ], [ 88, 89 ], [ 89, 90 ], [ 89, 91 ], [ 80, 92 ], [ 92, 93 ], [ 92, 94 ], [ 94, 95 ], [ 95, 96 ], [ 96, 97 ], [ 97, 98 ], [ 97, 99 ], [ 96, 100 ], [ 100, 101 ], [ 101, 102 ], [ 102, 103 ], [ 95, 104 ], [ 104, 105 ], [ 105, 106 ], [ 106, 107 ], [ 106, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 105, 112 ], [ 112, 113 ], [ 113, 114 ], [ 113, 115 ], [ 94, 116 ], [ 116, 117 ], [ 117, 118 ], [ 118, 119 ], [ 80, 120 ], [ 120, 121 ], [ 120, 122 ], [ 122, 123 ], [ 123, 124 ], [ 124, 125 ], [ 125, 126 ], [ 124, 127 ], [ 127, 128 ], [ 80, 129 ], [ 129, 130 ], [ 129, 131 ], [ 131, 132 ], [ 132, 133 ], [ 133, 134 ], [ 134, 135 ], [ 133, 136 ], [ 136, 137 ], [ 80, 138 ], [ 138, 139 ], [ 138, 140 ], [ 140, 141 ], [ 141, 142 ], [ 142, 143 ], [ 143, 144 ], [ 142, 145 ], [ 145, 146 ], [ 80, 147 ], [ 147, 148 ], [ 147, 149 ], [ 149, 150 ], [ 150, 151 ], [ 150, 152 ], [ 149, 153 ], [ 153, 154 ], [ 154, 155 ], [ 154, 156 ], [ 156, 157 ], [ 157, 158 ], [ 158, 159 ], [ 153, 160 ], [ 160, 161 ], [ 161, 162 ], [ 161, 163 ], [ 163, 164 ], [ 164, 165 ], [ 149, 166 ], [ 166, 167 ], [ 0, 168 ], [ 168, 169 ], [ 168, 170 ] ]
[ "\n\nimport java.util.*;\nimport java.io.*;\n\n\npublic class Main {\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }\n\n\n // public static PrintWriter out;\n\n public static class MyScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n\n }\n }", "import java.util.*;", "util.*", "java", "import java.io.*;", "io.*", "java", "public class Main {\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }\n\n\n // public static PrintWriter out;\n\n public static class MyScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n\n }\n }", "Main", "public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }", "main", "{\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }", "MyScanner sc = new MyScanner();", "sc", "new MyScanner()", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int count = 0;", "count", "0", "if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }", "a >= k", "a", "k", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "{\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }", "count += a", "count", "a", "k -= a", "k", "a", "if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }", "b >= k", "b", "k", "{\n System.out.println(count);\n }", "System.out.println(count)", "System.out.println", "System.out", "System", "System.out", "count", "{\n System.out.println(count - (k - b));\n }", "System.out.println(count - (k - b))", "System.out.println", "System.out", "System", "System.out", "count - (k - b)", "count", "(k - b)", "k", "b", "String[] args", "args", "public static class MyScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n\n }", "MyScanner", "BufferedReader br;", "br", "StringTokenizer st;", "st", "public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "MyScanner", "{\n br = new BufferedReader(new InputStreamReader(System.in));\n }", "br = new BufferedReader(new InputStreamReader(System.in))", "br", "new BufferedReader(new InputStreamReader(System.in))", "String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "next", "{\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }", "while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "st == null || !st.hasMoreElements()", "st == null", "st", "null", "!st.hasMoreElements()", "st.hasMoreElements()", "st.hasMoreElements", "st", "{\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n st = new StringTokenizer(br.readLine());\n }", "st = new StringTokenizer(br.readLine())", "st", "new StringTokenizer(br.readLine())", "return st.nextToken();", "st.nextToken()", "st.nextToken", "st", "int nextInt() {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "long nextLong() {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next", "double nextDouble() {\n return Double.parseDouble(next());\n }", "nextDouble", "{\n return Double.parseDouble(next());\n }", "return Double.parseDouble(next());", "Double.parseDouble(next())", "Double.parseDouble", "Double", "next()", "next", "String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "nextLine", "{\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }", "String str = \"\";", "str", "\"\"", "try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }", "catch (IOException e) {\n e.printStackTrace();\n }", "IOException e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n str = br.readLine();\n }", "str = br.readLine()", "str", "br.readLine()", "br.readLine", "br", "return str;", "str", "public class Main {\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }\n\n\n // public static PrintWriter out;\n\n public static class MyScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n\n }\n }", "public class Main {\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n //out = new PrintWriter(new java.io.BufferedOutputStream(System.out));\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n int count = 0;\n if (a >= k) {\n System.out.println(k);\n } else {\n count += a;\n k -= a;\n if (b >= k) {\n System.out.println(count);\n } else {\n System.out.println(count - (k - b));\n }\n }\n\n\n\n }\n\n\n // public static PrintWriter out;\n\n public static class MyScanner {\n BufferedReader br;\n StringTokenizer st;\n\n public MyScanner() {\n br = new BufferedReader(new InputStreamReader(System.in));\n }\n\n String next() {\n while (st == null || !st.hasMoreElements()) {\n try {\n st = new StringTokenizer(br.readLine());\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n return st.nextToken();\n }\n\n int nextInt() {\n return Integer.parseInt(next());\n }\n\n long nextLong() {\n return Long.parseLong(next());\n }\n\n double nextDouble() {\n return Double.parseDouble(next());\n }\n\n String nextLine(){\n String str = \"\";\n try {\n str = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return str;\n }\n\n }\n }", "Main" ]
import java.util.*; import java.io.*; public class Main { public static void main(String[] args) { MyScanner sc = new MyScanner(); //out = new PrintWriter(new java.io.BufferedOutputStream(System.out)); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int count = 0; if (a >= k) { System.out.println(k); } else { count += a; k -= a; if (b >= k) { System.out.println(count); } else { System.out.println(count - (k - b)); } } } // public static PrintWriter out; public static class MyScanner { BufferedReader br; StringTokenizer st; public MyScanner() { br = new BufferedReader(new InputStreamReader(System.in)); } String next() { while (st == null || !st.hasMoreElements()) { try { st = new StringTokenizer(br.readLine()); } catch (IOException e) { e.printStackTrace(); } } return st.nextToken(); } int nextInt() { return Integer.parseInt(next()); } long nextLong() { return Long.parseLong(next()); } double nextDouble() { return Double.parseDouble(next()); } String nextLine(){ String str = ""; try { str = br.readLine(); } catch (IOException e) { e.printStackTrace(); } return str; } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 2, 2, 17, 13, 13, 13, 23, 13, 6, 13, 41, 13, 20, 41, 13, 12, 13, 30, 38, 5, 13, 30, 30, 42, 2, 2, 13, 17, 40, 4, 18, 13, 30, 0, 13, 20, 29, 4, 18, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13, 12, 13, 30, 29, 4, 18, 13, 4, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], [ 11, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 11, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 11, 25 ], [ 25, 26 ], [ 25, 27 ], [ 27, 28 ], [ 28, 29 ], [ 11, 30 ], [ 30, 31 ], [ 30, 32 ], [ 32, 33 ], [ 33, 34 ], [ 11, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 40, 45 ], [ 35, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 49, 50 ], [ 49, 51 ], [ 46, 52 ], [ 52, 53 ], [ 53, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 53, 58 ], [ 46, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 60, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 65, 71 ], [ 9, 72 ], [ 72, 73 ], [ 7, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 76, 78 ], [ 74, 79 ], [ 79, 80 ], [ 74, 81 ], [ 81, 82 ], [ 81, 83 ], [ 83, 84 ], [ 84, 85 ], [ 85, 86 ], [ 85, 87 ], [ 84, 88 ], [ 88, 89 ], [ 89, 90 ], [ 90, 91 ], [ 91, 92 ], [ 91, 93 ], [ 90, 94 ], [ 94, 95 ], [ 95, 96 ], [ 96, 97 ], [ 89, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 83, 102 ], [ 102, 103 ], [ 103, 104 ], [ 104, 105 ], [ 74, 106 ], [ 106, 107 ], [ 106, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 111, 112 ], [ 110, 113 ], [ 113, 114 ], [ 74, 115 ], [ 115, 116 ], [ 115, 117 ], [ 117, 118 ], [ 118, 119 ], [ 119, 120 ], [ 120, 121 ], [ 119, 122 ], [ 122, 123 ] ]
[ "import java.io.*;\nimport java.util.*;\n\nclass Main {\n\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n\n if(k <= a){\n System.out.println(k);\n }\n else if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }\n }\n\n static class MyScanner {\n BufferedReader reader = new BufferedReader(new InputStreamReader(System.in), 1 << 15);\n StringTokenizer tokenizer;\n \n String next() {\n try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }\n return tokenizer.nextToken();\n }\n \n int nextInt() {\n return Integer.parseInt(next());\n }\n \n long nextLong() {\n return Long.parseLong(next());\n }\n }\n}", "import java.io.*;", "io.*", "java", "import java.util.*;", "util.*", "java", "class Main {\n\n public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n\n if(k <= a){\n System.out.println(k);\n }\n else if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }\n }\n\n static class MyScanner {\n BufferedReader reader = new BufferedReader(new InputStreamReader(System.in), 1 << 15);\n StringTokenizer tokenizer;\n \n String next() {\n try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }\n return tokenizer.nextToken();\n }\n \n int nextInt() {\n return Integer.parseInt(next());\n }\n \n long nextLong() {\n return Long.parseLong(next());\n }\n }\n}", "Main", "public static void main(String[] args) {\n MyScanner sc = new MyScanner();\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n\n if(k <= a){\n System.out.println(k);\n }\n else if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }\n }", "main", "{\n MyScanner sc = new MyScanner();\n \n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n\n if(k <= a){\n System.out.println(k);\n }\n else if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }\n }", "MyScanner sc = new MyScanner();", "sc", "new MyScanner()", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if(k <= a){\n System.out.println(k);\n }\n else if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }", "k <= a", "k", "a", "{\n System.out.println(k);\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k <= a+b){\n System.out.println(a);\n }\n else{\n System.out.println(2*a+b-k);\n }", "k <= a+b", "k", "a+b", "a", "b", "{\n System.out.println(a);\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n System.out.println(2*a+b-k);\n }", "System.out.println(2*a+b-k)", "System.out.println", "System.out", "System", "System.out", "2*a+b-k", "2*a+b", "2*a", "2", "a", "b", "k", "String[] args", "args", "static class MyScanner {\n BufferedReader reader = new BufferedReader(new InputStreamReader(System.in), 1 << 15);\n StringTokenizer tokenizer;\n \n String next() {\n try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }\n return tokenizer.nextToken();\n }\n \n int nextInt() {\n return Integer.parseInt(next());\n }\n \n long nextLong() {\n return Long.parseLong(next());\n }\n }", "MyScanner", "BufferedReader reader = new BufferedReader(new InputStreamReader(System.in), 1 << 15);", "reader", "new BufferedReader(new InputStreamReader(System.in), 1 << 15)", "StringTokenizer tokenizer;", "tokenizer", "String next() {\n try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }\n return tokenizer.nextToken();\n }", "next", "{\n try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }\n return tokenizer.nextToken();\n }", "try {\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n } catch (IOException ignored) {\n }", "catch (IOException ignored) {\n }", "IOException ignored", "{\n }", "{\n while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }\n }", "while (tokenizer == null || !tokenizer.hasMoreTokens()) {\n tokenizer = new StringTokenizer(reader.readLine());\n }", "tokenizer == null || !tokenizer.hasMoreTokens()", "tokenizer == null", "tokenizer", "null", "!tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens()", "tokenizer.hasMoreTokens", "tokenizer", "{\n tokenizer = new StringTokenizer(reader.readLine());\n }", "tokenizer = new StringTokenizer(reader.readLine())", "tokenizer", "new StringTokenizer(reader.readLine())", "return tokenizer.nextToken();", "tokenizer.nextToken()", "tokenizer.nextToken", "tokenizer", "int nextInt() {\n return Integer.parseInt(next());\n }", "nextInt", "{\n return Integer.parseInt(next());\n }", "return Integer.parseInt(next());", "Integer.parseInt(next())", "Integer.parseInt", "Integer", "next()", "next", "long nextLong() {\n return Long.parseLong(next());\n }", "nextLong", "{\n return Long.parseLong(next());\n }", "return Long.parseLong(next());", "Long.parseLong(next())", "Long.parseLong", "Long", "next()", "next" ]
import java.io.*; import java.util.*; class Main { public static void main(String[] args) { MyScanner sc = new MyScanner(); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); if(k <= a){ System.out.println(k); } else if(k <= a+b){ System.out.println(a); } else{ System.out.println(2*a+b-k); } } static class MyScanner { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in), 1 << 15); StringTokenizer tokenizer; String next() { try { while (tokenizer == null || !tokenizer.hasMoreTokens()) { tokenizer = new StringTokenizer(reader.readLine()); } } catch (IOException ignored) { } return tokenizer.nextToken(); } int nextInt() { return Integer.parseInt(next()); } long nextLong() { return Long.parseLong(next()); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 2, 17, 13, 14, 2, 13, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 74, 5 ], [ 74, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 42, 43 ], [ 42, 44 ], [ 35, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 48, 49 ], [ 48, 50 ], [ 45, 51 ], [ 51, 52 ], [ 52, 53 ], [ 52, 54 ], [ 45, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 8, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 65, 70 ], [ 6, 71 ], [ 71, 72 ], [ 0, 73 ], [ 73, 74 ], [ 73, 75 ] ]
[ "import java.util.Scanner;\npublic class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}\n\n}", "Main", "public static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "int max = 0;", "max", "0", "if(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}", "a >= k", "a", "k", "{\n\t\t\tmax = 1 * k;\n\t\t}", "max = 1 * k", "max", "1 * k", "1", "k", "if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}", "b > k - a", "b", "k - a", "k", "a", "{\n\t\t\tmax = a;\n\t\t}", "max = a", "max", "a", "{\n\t\t\tmax = a - (k - a - b);\n\t\t}", "max = a - (k - a - b)", "max", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "System.out.println(max)", "System.out.println", "System.out", "System", "System.out", "max", "String[] args", "args", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}\n\n}", "public class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a = sc.nextInt();\n\t\tint b = sc.nextInt();\n\t\tint c = sc.nextInt();\n\t\tint k = sc.nextInt();\n\t\tint max = 0;\n\t\tif(a >= k){\n\t\t\tmax = 1 * k;\n\t\t}else if(b > k - a){\n\t\t\tmax = a;\n\t\t}else{\n\t\t\tmax = a - (k - a - b);\n\t\t}\n\t\tSystem.out.println(max);\n\t}\n\n}", "Main" ]
import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); int max = 0; if(a >= k){ max = 1 * k; }else if(b > k - a){ max = a; }else{ max = a - (k - a - b); } System.out.println(max); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 13, 30, 14, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 13, 2, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 83, 5 ], [ 83, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 8, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 43, 47 ], [ 47, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 49, 53 ], [ 48, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 55, 60 ], [ 47, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 62, 66 ], [ 61, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 75, 77 ], [ 77, 78 ], [ 77, 79 ], [ 6, 80 ], [ 80, 81 ], [ 0, 82 ], [ 82, 83 ], [ 82, 84 ] ]
[ "//package atcoder;\n \nimport java.util.*;\n \npublic class Main{\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}\n}", "import java.util.*;", "util.*", "java", "public class Main{\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "long A = sc.nextLong();", "A", "sc.nextLong()", "sc.nextLong", "sc", "long B = sc.nextLong();", "B", "sc.nextLong()", "sc.nextLong", "sc", "long C = sc.nextLong();", "C", "sc.nextLong()", "sc.nextLong", "sc", "long K = sc.nextLong();", "K", "sc.nextLong()", "sc.nextLong", "sc", "if(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}", "A>=K", "A", "K", "{\n\t\t\tSystem.out.println(K);\n\t\t}", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}", "A<K", "A", "K", "{\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}", "if((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}", "(K-A)<=B", "(K-A)", "K", "A", "B", "{\n\t\t\t\tSystem.out.println(A);\n\t\t\t}", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "if((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}", "(K-A)>B", "(K-A)", "K", "A", "B", "{\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}", "System.out.println(A-(K-(A+B)))", "System.out.println", "System.out", "System", "System.out", "A-(K-(A+B))", "A", "(K-(A+B))", "K", "(A+B)", "A", "B", "String[] args", "args", "public class Main{\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}\n}", "public class Main{\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tlong A = sc.nextLong();\n\t\tlong B = sc.nextLong();\n\t\tlong C = sc.nextLong();\n\t\tlong K = sc.nextLong();\n\t\t\n\t\tif(A>=K) {\n\t\t\tSystem.out.println(K);\n\t\t}\n\t\tif(A<K) {\n\t\t\tif((K-A)<=B) {\n\t\t\t\tSystem.out.println(A);\n\t\t\t}\n\t\t\tif((K-A)>B) {\n\t\t\t\tSystem.out.println(A-(K-(A+B)));\n\t\t\t}\n\t\t}\n\t}\n}", "Main" ]
//package atcoder; import java.util.*; public class Main{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); long A = sc.nextLong(); long B = sc.nextLong(); long C = sc.nextLong(); long K = sc.nextLong(); if(A>=K) { System.out.println(K); } if(A<K) { if((K-A)<=B) { System.out.println(A); } if((K-A)>B) { System.out.println(A-(K-(A+B))); } } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 18, 13, 13, 2, 17, 4, 18, 13, 30, 41, 13, 20, 41, 13, 4, 18, 4, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 41, 13, 4, 18, 13, 18, 13, 17, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 4, 18, 13, 13, 13, 30, 0, 13, 2, 13, 13, 4, 18, 18, 13, 13, 2, 13, 13, 23, 13, 12, 13, 30, 0, 18, 13, 13, 17, 41, 13, 4, 18, 4, 18, 13, 13, 42, 4, 18, 13, 30, 41, 13, 4, 18, 13, 14, 40, 18, 13, 13, 30, 4, 13, 13, 13, 13, 23, 13, 23, 13, 23, 13, 12, 13, 30, 29, 4, 13, 13, 2, 13, 17, 13, 23, 13, 23, 13, 12, 13, 30, 14, 2, 13, 17, 29, 17, 41, 13, 2, 4, 13, 13, 2, 13, 17, 13, 13, 0, 13, 2, 2, 13, 13, 13, 29, 8, 2, 2, 13, 17, 17, 13, 2, 2, 13, 13, 13, 23, 13, 23, 13, 23, 13, 12, 13, 30, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 18, 13, 13, 41, 13, 18, 13, 13, 0, 18, 13, 13, 18, 13, 13, 0, 18, 13, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 0, 18, 36, 13, 13, 23, 13, 23, 13, 23, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 31, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 27, 41 ], [ 41, 42 ], [ 42, 43 ], [ 42, 44 ], [ 41, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 47, 52 ], [ 41, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 55, 58 ], [ 58, 59 ], [ 58, 60 ], [ 41, 61 ], [ 61, 62 ], [ 61, 63 ], [ 63, 64 ], [ 64, 65 ], [ 63, 66 ], [ 66, 67 ], [ 66, 68 ], [ 41, 69 ], [ 69, 70 ], [ 69, 71 ], [ 71, 72 ], [ 72, 73 ], [ 71, 74 ], [ 74, 75 ], [ 74, 76 ], [ 41, 77 ], [ 77, 78 ], [ 77, 79 ], [ 79, 80 ], [ 80, 81 ], [ 79, 82 ], [ 82, 83 ], [ 82, 84 ], [ 41, 85 ], [ 85, 86 ], [ 86, 87 ], [ 86, 88 ], [ 88, 89 ], [ 88, 90 ], [ 85, 91 ], [ 91, 92 ], [ 92, 93 ], [ 93, 94 ], [ 94, 95 ], [ 94, 96 ], [ 92, 97 ], [ 97, 98 ], [ 98, 99 ], [ 97, 100 ], [ 97, 101 ], [ 85, 102 ], [ 102, 103 ], [ 103, 104 ], [ 103, 105 ], [ 105, 106 ], [ 105, 107 ], [ 102, 108 ], [ 108, 109 ], [ 109, 110 ], [ 110, 111 ], [ 110, 112 ], [ 108, 113 ], [ 113, 114 ], [ 113, 115 ], [ 24, 116 ], [ 116, 117 ], [ 22, 118 ], [ 118, 119 ], [ 118, 120 ], [ 120, 121 ], [ 121, 122 ], [ 122, 123 ], [ 122, 124 ], [ 121, 125 ], [ 120, 126 ], [ 126, 127 ], [ 126, 128 ], [ 128, 129 ], [ 129, 130 ], [ 130, 131 ], [ 131, 132 ], [ 130, 133 ], [ 120, 134 ], [ 134, 135 ], [ 135, 136 ], [ 136, 137 ], [ 134, 138 ], [ 138, 139 ], [ 139, 140 ], [ 139, 141 ], [ 141, 142 ], [ 142, 143 ], [ 138, 144 ], [ 144, 145 ], [ 145, 146 ], [ 146, 147 ], [ 146, 148 ], [ 144, 149 ], [ 149, 150 ], [ 150, 151 ], [ 150, 152 ], [ 150, 153 ], [ 150, 154 ], [ 118, 155 ], [ 155, 156 ], [ 118, 157 ], [ 157, 158 ], [ 118, 159 ], [ 159, 160 ], [ 22, 161 ], [ 161, 162 ], [ 161, 163 ], [ 163, 164 ], [ 164, 165 ], [ 165, 166 ], [ 165, 167 ], [ 165, 168 ], [ 168, 169 ], [ 168, 170 ], [ 165, 171 ], [ 161, 172 ], [ 172, 173 ], [ 161, 174 ], [ 174, 175 ], [ 22, 176 ], [ 176, 177 ], [ 176, 178 ], [ 178, 179 ], [ 179, 180 ], [ 180, 181 ], [ 180, 182 ], [ 179, 183 ], [ 183, 184 ], [ 178, 185 ], [ 185, 186 ], [ 185, 187 ], [ 187, 188 ], [ 188, 189 ], [ 188, 190 ], [ 188, 191 ], [ 191, 192 ], [ 191, 193 ], [ 188, 194 ], [ 187, 195 ], [ 178, 196 ], [ 196, 197 ], [ 196, 198 ], [ 198, 199 ], [ 199, 200 ], [ 199, 201 ], [ 198, 202 ], [ 178, 203 ], [ 203, 204 ], [ 204, 205 ], [ 205, 206 ], [ 206, 207 ], [ 206, 208 ], [ 205, 209 ], [ 204, 210 ], [ 204, 211 ], [ 211, 212 ], [ 212, 213 ], [ 212, 214 ], [ 211, 215 ], [ 176, 216 ], [ 216, 217 ], [ 176, 218 ], [ 218, 219 ], [ 176, 220 ], [ 220, 221 ], [ 22, 222 ], [ 222, 223 ], [ 222, 224 ], [ 224, 225 ], [ 225, 226 ], [ 225, 227 ], [ 224, 228 ], [ 228, 229 ], [ 229, 230 ], [ 230, 231 ], [ 230, 232 ], [ 228, 233 ], [ 233, 234 ], [ 233, 235 ], [ 235, 236 ], [ 235, 237 ], [ 228, 238 ], [ 238, 239 ], [ 239, 240 ], [ 228, 241 ], [ 242, 242 ], [ 242, 243 ], [ 243, 244 ], [ 243, 245 ], [ 245, 246 ], [ 246, 247 ], [ 245, 248 ], [ 248, 249 ], [ 248, 250 ], [ 242, 251 ], [ 251, 252 ], [ 251, 253 ], [ 253, 254 ], [ 253, 255 ], [ 242, 256 ], [ 256, 257 ], [ 257, 258 ], [ 257, 259 ], [ 256, 260 ], [ 260, 261 ], [ 260, 262 ], [ 242, 263 ], [ 263, 264 ], [ 264, 265 ], [ 264, 266 ], [ 263, 267 ], [ 222, 268 ], [ 268, 269 ], [ 22, 270 ], [ 270, 271 ], [ 270, 272 ], [ 272, 273 ], [ 270, 274 ], [ 274, 275 ], [ 270, 276 ], [ 276, 277 ], [ 270, 278 ], [ 278, 279 ], [ 270, 280 ], [ 280, 281 ], [ 280, 282 ], [ 282, 283 ], [ 283, 284 ], [ 284, 285 ], [ 284, 286 ], [ 283, 287 ], [ 282, 288 ], [ 288, 289 ], [ 289, 290 ], [ 289, 291 ], [ 288, 292 ], [ 282, 293 ], [ 293, 294 ], [ 294, 295 ], [ 294, 296 ], [ 293, 297 ], [ 282, 298 ], [ 298, 299 ], [ 299, 300 ], [ 299, 301 ], [ 298, 302 ], [ 280, 303 ], [ 303, 304 ], [ 280, 305 ], [ 305, 306 ], [ 280, 307 ], [ 307, 308 ], [ 280, 309 ], [ 309, 310 ] ]
[ "import javax.swing.text.html.HTMLDocument;\nimport java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.io.PrintWriter;\nimport java.math.BigInteger;\nimport java.nio.Buffer;\nimport java.util.*;\n\nclass Main {\n public static void main(String[] args){\n try {\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n } catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }\n }\n static void dfs(ArrayList<HashSet<Integer>> list,boolean[] vis,int i){\n vis[i]=true;\n Iterator<Integer> it=list.get(i).iterator();\n while(it.hasNext()){\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }\n }\n static int modInverse(int x,int m){\n return power(x,m-2,m);\n }\n static int power(int x, int y, int m)\n {\n if (y == 0)\n return 1;\n\n long p = power(x, y / 2, m) % m;\n p = (p * p) % m;\n\n return (int)((y%2==0)? p : (x*p)%m);\n }\n static void shuffle(String[] a) {\n Random get = new Random();\n for (int i = 0; i < a.length; i++) {\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }\n }\n static class quad{\n int a,b,c,d;\n public quad(int a,int b,int c,int d){\n this.a=a;\n this.b=b;\n this.c=c;\n this.d=d;\n }\n }\n}", "import javax.swing.text.html.HTMLDocument;", "HTMLDocument", "javax.swing.text.html", "import java.io.BufferedReader;", "BufferedReader", "java.io", "import java.io.InputStreamReader;", "InputStreamReader", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.math.BigInteger;", "BigInteger", "java.math", "import java.nio.Buffer;", "Buffer", "java.nio", "import java.util.*;", "util.*", "java", "class Main {\n public static void main(String[] args){\n try {\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n } catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }\n }\n static void dfs(ArrayList<HashSet<Integer>> list,boolean[] vis,int i){\n vis[i]=true;\n Iterator<Integer> it=list.get(i).iterator();\n while(it.hasNext()){\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }\n }\n static int modInverse(int x,int m){\n return power(x,m-2,m);\n }\n static int power(int x, int y, int m)\n {\n if (y == 0)\n return 1;\n\n long p = power(x, y / 2, m) % m;\n p = (p * p) % m;\n\n return (int)((y%2==0)? p : (x*p)%m);\n }\n static void shuffle(String[] a) {\n Random get = new Random();\n for (int i = 0; i < a.length; i++) {\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }\n }\n static class quad{\n int a,b,c,d;\n public quad(int a,int b,int c,int d){\n this.a=a;\n this.b=b;\n this.c=c;\n this.d=d;\n }\n }\n}", "Main", "public static void main(String[] args){\n try {\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n } catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }\n }", "main", "{\n try {\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n } catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }\n }", "try {\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n } catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }", "catch (Exception e) {\n System.out.println(\"kkkk \"+ e.getMessage());\n }", "Exception e", "{\n System.out.println(\"kkkk \"+ e.getMessage());\n }", "System.out.println(\"kkkk \"+ e.getMessage())", "System.out.println", "System.out", "System", "System.out", "\"kkkk \"+ e.getMessage()", "\"kkkk \"", "e.getMessage()", "e.getMessage", "e", "{\n BufferedReader br=new BufferedReader(new InputStreamReader(System.in));\n String[] ss=br.readLine().split(\" \");\n long a=Long.parseLong(ss[0]);\n long b=Long.parseLong(ss[1]);\n long c=Long.parseLong(ss[2]);\n long k=Long.parseLong(ss[3]);\n if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }\n }", "BufferedReader br=new BufferedReader(new InputStreamReader(System.in));", "br", "new BufferedReader(new InputStreamReader(System.in))", "String[] ss=br.readLine().split(\" \");", "ss", "br.readLine().split(\" \")", "br.readLine().split", "br.readLine()", "br.readLine", "br", "\" \"", "long a=Long.parseLong(ss[0]);", "a", "Long.parseLong(ss[0])", "Long.parseLong", "Long", "ss[0]", "ss", "0", "long b=Long.parseLong(ss[1]);", "b", "Long.parseLong(ss[1])", "Long.parseLong", "Long", "ss[1]", "ss", "1", "long c=Long.parseLong(ss[2]);", "c", "Long.parseLong(ss[2])", "Long.parseLong", "Long", "ss[2]", "ss", "2", "long k=Long.parseLong(ss[3]);", "k", "Long.parseLong(ss[3])", "Long.parseLong", "Long", "ss[3]", "ss", "3", "if(k<=a+b){\n System.out.println(Math.min(k,a));\n }else{\n k-=(a+b);\n System.out.println(a-k);\n }", "k<=a+b", "k", "a+b", "a", "b", "{\n System.out.println(Math.min(k,a));\n }", "System.out.println(Math.min(k,a))", "System.out.println", "System.out", "System", "System.out", "Math.min(k,a)", "Math.min", "Math", "k", "a", "{\n k-=(a+b);\n System.out.println(a-k);\n }", "k-=(a+b)", "k", "(a+b)", "a", "b", "System.out.println(a-k)", "System.out.println", "System.out", "System", "System.out", "a-k", "a", "k", "String[] args", "args", "static void dfs(ArrayList<HashSet<Integer>> list,boolean[] vis,int i){\n vis[i]=true;\n Iterator<Integer> it=list.get(i).iterator();\n while(it.hasNext()){\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }\n }", "dfs", "{\n vis[i]=true;\n Iterator<Integer> it=list.get(i).iterator();\n while(it.hasNext()){\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }\n }", "vis[i]=true", "vis[i]", "vis", "i", "true", "Iterator<Integer> it=list.get(i).iterator();", "it", "list.get(i).iterator()", "list.get(i).iterator", "list.get(i)", "list.get", "list", "i", "while(it.hasNext()){\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }", "it.hasNext()", "it.hasNext", "it", "{\n int u=it.next();\n if(!vis[u]){\n dfs(list,vis,u);\n }\n }", "int u=it.next();", "u", "it.next()", "it.next", "it", "if(!vis[u]){\n dfs(list,vis,u);\n }", "!vis[u]", "vis[u]", "vis", "u", "{\n dfs(list,vis,u);\n }", "dfs(list,vis,u)", "dfs", "list", "vis", "u", "ArrayList<HashSet<Integer>> list", "list", "boolean[] vis", "vis", "int i", "i", "static int modInverse(int x,int m){\n return power(x,m-2,m);\n }", "modInverse", "{\n return power(x,m-2,m);\n }", "return power(x,m-2,m);", "power(x,m-2,m)", "power", "x", "m-2", "m", "2", "m", "int x", "x", "int m", "m", "static int power(int x, int y, int m)\n {\n if (y == 0)\n return 1;\n\n long p = power(x, y / 2, m) % m;\n p = (p * p) % m;\n\n return (int)((y%2==0)? p : (x*p)%m);\n }", "power", "{\n if (y == 0)\n return 1;\n\n long p = power(x, y / 2, m) % m;\n p = (p * p) % m;\n\n return (int)((y%2==0)? p : (x*p)%m);\n }", "if (y == 0)\n return 1;", "y == 0", "y", "0", "return 1;", "1", "long p = power(x, y / 2, m) % m;", "p", "power(x, y / 2, m) % m", "power(x, y / 2, m)", "power", "x", "y / 2", "y", "2", "m", "m", "p = (p * p) % m", "p", "(p * p) % m", "(p * p)", "p", "p", "m", "return (int)((y%2==0)? p : (x*p)%m);", "(int)((y%2==0)? p : (x*p)%m)", "(y%2==0)", "y%2", "y", "2", "0", "p", "(x*p)%m", "(x*p)", "x", "p", "m", "int x", "x", "int y", "y", "int m", "m", "static void shuffle(String[] a) {\n Random get = new Random();\n for (int i = 0; i < a.length; i++) {\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }\n }", "shuffle", "{\n Random get = new Random();\n for (int i = 0; i < a.length; i++) {\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }\n }", "Random get = new Random();", "get", "new Random()", "for (int i = 0; i < a.length; i++) {\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }", "int i = 0;", "int i = 0;", "i", "0", "i < a.length", "i", "a.length", "a", "a.length", "i++", "i++", "i", "{\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }", "{\n int r = get.nextInt(a.length);\n String temp = a[i];\n a[i] = a[r];\n a[r] = temp;\n }", "int r = get.nextInt(a.length);", "r", "get.nextInt(a.length)", "get.nextInt", "get", "a.length", "a", "a.length", "String temp = a[i];", "temp", "a[i]", "a", "i", "a[i] = a[r]", "a[i]", "a", "i", "a[r]", "a", "r", "a[r] = temp", "a[r]", "a", "r", "temp", "String[] a", "a", "static class quad{\n int a,b,c,d;\n public quad(int a,int b,int c,int d){\n this.a=a;\n this.b=b;\n this.c=c;\n this.d=d;\n }\n }", "quad", "int a", "a", "b", "b", "c", "c", "d;", "d", "public quad(int a,int b,int c,int d){\n this.a=a;\n this.b=b;\n this.c=c;\n this.d=d;\n }", "quad", "{\n this.a=a;\n this.b=b;\n this.c=c;\n this.d=d;\n }", "this.a=a", "this.a", "this", "this.a", "a", "this.b=b", "this.b", "this", "this.b", "b", "this.c=c", "this.c", "this", "this.c", "c", "this.d=d", "this.d", "this", "this.d", "d", "int a", "a", "int b", "b", "int c", "c", "int d", "d" ]
import javax.swing.text.html.HTMLDocument; import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.PrintWriter; import java.math.BigInteger; import java.nio.Buffer; import java.util.*; class Main { public static void main(String[] args){ try { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); String[] ss=br.readLine().split(" "); long a=Long.parseLong(ss[0]); long b=Long.parseLong(ss[1]); long c=Long.parseLong(ss[2]); long k=Long.parseLong(ss[3]); if(k<=a+b){ System.out.println(Math.min(k,a)); }else{ k-=(a+b); System.out.println(a-k); } } catch (Exception e) { System.out.println("kkkk "+ e.getMessage()); } } static void dfs(ArrayList<HashSet<Integer>> list,boolean[] vis,int i){ vis[i]=true; Iterator<Integer> it=list.get(i).iterator(); while(it.hasNext()){ int u=it.next(); if(!vis[u]){ dfs(list,vis,u); } } } static int modInverse(int x,int m){ return power(x,m-2,m); } static int power(int x, int y, int m) { if (y == 0) return 1; long p = power(x, y / 2, m) % m; p = (p * p) % m; return (int)((y%2==0)? p : (x*p)%m); } static void shuffle(String[] a) { Random get = new Random(); for (int i = 0; i < a.length; i++) { int r = get.nextInt(a.length); String temp = a[i]; a[i] = a[r]; a[r] = temp; } } static class quad{ int a,b,c,d; public quad(int a,int b,int c,int d){ this.a=a; this.b=b; this.c=c; this.d=d; } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 2, 2, 17, 13, 13, 13, 30, 4, 18, 18, 13, 13, 17, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 37, 41 ], [ 41, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 44, 46 ], [ 42, 47 ], [ 37, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 51, 52 ], [ 51, 53 ], [ 48, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 57, 58 ], [ 57, 59 ], [ 55, 60 ], [ 48, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 67, 73 ], [ 32, 74 ], [ 74, 75 ], [ 75, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 75, 80 ], [ 6, 81 ], [ 81, 82 ] ]
[ "import java.util.Scanner;\n\nclass Main{\n public static void main(String args[]){\n\tScanner sc = new Scanner(System.in);\n\tint a = sc.nextInt();\n\tint b = sc.nextInt();\n\tint c = sc.nextInt();\n\tint k = sc.nextInt();\n\tif(k>0){\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}else{\n\t System.out.println(0);\n\t}\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "class Main{\n public static void main(String args[]){\n\tScanner sc = new Scanner(System.in);\n\tint a = sc.nextInt();\n\tint b = sc.nextInt();\n\tint c = sc.nextInt();\n\tint k = sc.nextInt();\n\tif(k>0){\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}else{\n\t System.out.println(0);\n\t}\n }\n}", "Main", "public static void main(String args[]){\n\tScanner sc = new Scanner(System.in);\n\tint a = sc.nextInt();\n\tint b = sc.nextInt();\n\tint c = sc.nextInt();\n\tint k = sc.nextInt();\n\tif(k>0){\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}else{\n\t System.out.println(0);\n\t}\n }", "main", "{\n\tScanner sc = new Scanner(System.in);\n\tint a = sc.nextInt();\n\tint b = sc.nextInt();\n\tint c = sc.nextInt();\n\tint k = sc.nextInt();\n\tif(k>0){\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}else{\n\t System.out.println(0);\n\t}\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if(k>0){\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}else{\n\t System.out.println(0);\n\t}", "k>0", "k", "0", "{\n\t if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }\n\t}", "if(k<a){\n\t\tSystem.out.println(k);\n\t }else if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }", "k<a", "k", "a", "{\n\t\tSystem.out.println(k);\n\t }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k<=a+b){\n\t\tSystem.out.println(a);\n\t }else{\n\t\tSystem.out.println(2*a+b-k);\n\t }", "k<=a+b", "k", "a+b", "a", "b", "{\n\t\tSystem.out.println(a);\n\t }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "{\n\t\tSystem.out.println(2*a+b-k);\n\t }", "System.out.println(2*a+b-k)", "System.out.println", "System.out", "System", "System.out", "2*a+b-k", "2*a+b", "2*a", "2", "a", "b", "k", "{\n\t System.out.println(0);\n\t}", "System.out.println(0)", "System.out.println", "System.out", "System", "System.out", "0", "String args[]", "args" ]
import java.util.Scanner; class Main{ public static void main(String args[]){ Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); if(k>0){ if(k<a){ System.out.println(k); }else if(k<=a+b){ System.out.println(a); }else{ System.out.println(2*a+b-k); } }else{ System.out.println(0); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 38, 5, 13, 30, 4, 18, 13, 30, 4, 18, 13, 30, 41, 13, 4, 18, 13, 14, 2, 13, 17, 29, 41, 13, 4, 18, 13, 14, 2, 13, 17, 29, 41, 13, 4, 18, 13, 14, 2, 13, 17, 29, 41, 13, 4, 18, 13, 14, 2, 2, 2, 13, 17, 2, 2, 2, 13, 13, 13, 13, 2, 2, 2, 13, 13, 13, 2, 17, 4, 18, 13, 17, 17, 29, 41, 13, 17, 41, 13, 13, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 0, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 0, 13, 17, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 13, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 0, 13, 13, 30, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 40, 13, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 212, 5 ], [ 212, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 13, 14 ], [ 13, 15 ], [ 15, 16 ], [ 16, 17 ], [ 17, 18 ], [ 12, 19 ], [ 19, 20 ], [ 20, 21 ], [ 21, 22 ], [ 12, 23 ], [ 23, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 23, 29 ], [ 29, 30 ], [ 30, 31 ], [ 30, 32 ], [ 29, 33 ], [ 23, 34 ], [ 34, 35 ], [ 34, 36 ], [ 36, 37 ], [ 37, 38 ], [ 23, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 23, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 47, 48 ], [ 23, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 49, 53 ], [ 23, 54 ], [ 54, 55 ], [ 54, 56 ], [ 56, 57 ], [ 57, 58 ], [ 23, 59 ], [ 59, 60 ], [ 61, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 66, 70 ], [ 65, 71 ], [ 61, 72 ], [ 72, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 73, 77 ], [ 72, 78 ], [ 78, 79 ], [ 78, 80 ], [ 80, 81 ], [ 81, 82 ], [ 80, 83 ], [ 80, 84 ], [ 59, 85 ], [ 23, 86 ], [ 86, 87 ], [ 86, 88 ], [ 23, 89 ], [ 89, 90 ], [ 89, 91 ], [ 23, 92 ], [ 92, 93 ], [ 93, 94 ], [ 93, 95 ], [ 92, 96 ], [ 96, 97 ], [ 97, 98 ], [ 98, 99 ], [ 98, 100 ], [ 97, 101 ], [ 101, 102 ], [ 102, 103 ], [ 103, 104 ], [ 104, 105 ], [ 104, 106 ], [ 102, 107 ], [ 107, 108 ], [ 107, 109 ], [ 102, 110 ], [ 110, 111 ], [ 111, 112 ], [ 102, 113 ], [ 114, 114 ], [ 114, 115 ], [ 115, 116 ], [ 101, 117 ], [ 117, 118 ], [ 117, 119 ], [ 97, 120 ], [ 120, 121 ], [ 121, 122 ], [ 122, 123 ], [ 123, 124 ], [ 123, 125 ], [ 121, 126 ], [ 126, 127 ], [ 126, 128 ], [ 121, 129 ], [ 129, 130 ], [ 130, 131 ], [ 121, 132 ], [ 133, 133 ], [ 133, 134 ], [ 134, 135 ], [ 120, 136 ], [ 136, 137 ], [ 136, 138 ], [ 23, 139 ], [ 139, 140 ], [ 140, 141 ], [ 140, 142 ], [ 139, 143 ], [ 143, 144 ], [ 144, 145 ], [ 145, 146 ], [ 145, 147 ], [ 144, 148 ], [ 148, 149 ], [ 149, 150 ], [ 149, 151 ], [ 144, 152 ], [ 152, 153 ], [ 153, 154 ], [ 153, 155 ], [ 23, 156 ], [ 156, 157 ], [ 157, 158 ], [ 157, 159 ], [ 156, 160 ], [ 160, 161 ], [ 161, 162 ], [ 162, 163 ], [ 162, 164 ], [ 161, 165 ], [ 165, 166 ], [ 166, 167 ], [ 167, 168 ], [ 168, 169 ], [ 168, 170 ], [ 166, 171 ], [ 171, 172 ], [ 171, 173 ], [ 166, 174 ], [ 174, 175 ], [ 175, 176 ], [ 166, 177 ], [ 178, 178 ], [ 178, 179 ], [ 179, 180 ], [ 165, 181 ], [ 181, 182 ], [ 181, 183 ], [ 161, 184 ], [ 184, 185 ], [ 185, 186 ], [ 186, 187 ], [ 187, 188 ], [ 187, 189 ], [ 185, 190 ], [ 190, 191 ], [ 190, 192 ], [ 185, 193 ], [ 193, 194 ], [ 194, 195 ], [ 185, 196 ], [ 197, 197 ], [ 197, 198 ], [ 198, 199 ], [ 184, 200 ], [ 200, 201 ], [ 200, 202 ], [ 23, 203 ], [ 203, 204 ], [ 204, 205 ], [ 205, 206 ], [ 205, 207 ], [ 203, 208 ], [ 6, 209 ], [ 209, 210 ], [ 0, 211 ], [ 211, 212 ], [ 211, 213 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }\n}", "Main", "public static void main(String[] args) {\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }", "main", "{\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }", "Scanner stdIn = new Scanner(System.in);", "stdIn", "new Scanner(System.in)", "try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }", "catch (Exception e) {\n e.printStackTrace();\n }", "Exception e", "{\n e.printStackTrace();\n }", "e.printStackTrace()", "e.printStackTrace", "e", "{\n stdIn.close();\n }", "stdIn.close()", "stdIn.close", "stdIn", "{\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n }", "int oneNum = stdIn.nextInt();", "oneNum", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "if (oneNum < 0) return;", "oneNum < 0", "oneNum", "0", "return;", "int zeroNum = stdIn.nextInt();", "zeroNum", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "if (zeroNum < 0) return;", "zeroNum < 0", "zeroNum", "0", "return;", "int minusOneNum = stdIn.nextInt();", "minusOneNum", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "if (minusOneNum < 0) return;", "minusOneNum < 0", "minusOneNum", "0", "return;", "int selectNum = stdIn.nextInt();", "selectNum", "stdIn.nextInt()", "stdIn.nextInt", "stdIn", "if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;", "selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)", "selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)", "selectNum < 1", "selectNum", "1", "(oneNum + zeroNum + minusOneNum) < selectNum", "(oneNum + zeroNum + minusOneNum)", "oneNum + zeroNum + minusOneNum", "oneNum", "zeroNum", "minusOneNum", "selectNum", "(oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)", "(oneNum + zeroNum + minusOneNum)", "oneNum + zeroNum + minusOneNum", "oneNum", "zeroNum", "minusOneNum", "2 * Math.pow(10, 9)", "2", "Math.pow(10, 9)", "Math.pow", "Math", "10", "9", "return;", "int maxValue = 0;", "maxValue", "0", "int restSelect = selectNum;", "restSelect", "selectNum", "if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }", "restSelect != 0", "restSelect", "0", "{\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }", "if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }", "oneNum <= restSelect", "oneNum", "restSelect", "{\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n }", "for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }", "int oneCnt = 0;", "int oneCnt = 0;", "oneCnt", "0", "oneCnt < oneNum", "oneCnt", "oneNum", "oneCnt++", "oneCnt++", "oneCnt", "{\n maxValue++;\n }", "{\n maxValue++;\n }", "maxValue++", "maxValue", "restSelect -= oneNum", "restSelect", "oneNum", "{\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }", "for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }", "int oneCnt = 0;", "int oneCnt = 0;", "oneCnt", "0", "oneCnt < restSelect", "oneCnt", "restSelect", "oneCnt++", "oneCnt++", "oneCnt", "{\n maxValue++;\n }", "{\n maxValue++;\n }", "maxValue++", "maxValue", "restSelect = 0", "restSelect", "0", "if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }", "restSelect != 0", "restSelect", "0", "{\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }", "if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }", "zeroNum <= restSelect", "zeroNum", "restSelect", "{\n restSelect -= zeroNum;\n }", "restSelect -= zeroNum", "restSelect", "zeroNum", "{\n restSelect -= restSelect;\n }", "restSelect -= restSelect", "restSelect", "restSelect", "if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }", "restSelect != 0", "restSelect", "0", "{\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }", "if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }", "minusOneNum <= restSelect", "minusOneNum", "restSelect", "{\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n }", "for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }", "int minusOneCnt = 0;", "int minusOneCnt = 0;", "minusOneCnt", "0", "minusOneCnt < minusOneNum", "minusOneCnt", "minusOneNum", "minusOneCnt++", "minusOneCnt++", "minusOneCnt", "{\n maxValue--;\n }", "{\n maxValue--;\n }", "maxValue--", "maxValue", "restSelect -= minusOneNum", "restSelect", "minusOneNum", "{\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }", "for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }", "int minusOneCnt = 0;", "int minusOneCnt = 0;", "minusOneCnt", "0", "minusOneCnt < restSelect", "minusOneCnt", "restSelect", "minusOneCnt++", "minusOneCnt++", "minusOneCnt", "{\n maxValue--;\n }", "{\n maxValue--;\n }", "maxValue--", "maxValue", "restSelect -= restSelect", "restSelect", "restSelect", "System.out.println(maxValue)", "System.out.println", "System.out", "System", "System.out", "maxValue", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner stdIn = new Scanner(System.in);\n try {\n int oneNum = stdIn.nextInt();\n if (oneNum < 0) return;\n int zeroNum = stdIn.nextInt();\n if (zeroNum < 0) return;\n int minusOneNum = stdIn.nextInt();\n if (minusOneNum < 0) return;\n int selectNum = stdIn.nextInt();\n if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return;\n int maxValue = 0;\n int restSelect = selectNum;\n if (restSelect != 0) {\n if (oneNum <= restSelect) {\n for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) {\n maxValue++;\n }\n restSelect -= oneNum;\n } else {\n for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) {\n maxValue++;\n }\n restSelect = 0;\n }\n }\n if (restSelect != 0) {\n if (zeroNum <= restSelect) {\n restSelect -= zeroNum;\n } else {\n restSelect -= restSelect;\n }\n }\n if (restSelect != 0) {\n if (minusOneNum <= restSelect) {\n for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= minusOneNum;\n } else {\n for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) {\n maxValue--;\n }\n restSelect -= restSelect;\n }\n }\n System.out.println(maxValue);\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n stdIn.close();\n }\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner stdIn = new Scanner(System.in); try { int oneNum = stdIn.nextInt(); if (oneNum < 0) return; int zeroNum = stdIn.nextInt(); if (zeroNum < 0) return; int minusOneNum = stdIn.nextInt(); if (minusOneNum < 0) return; int selectNum = stdIn.nextInt(); if (selectNum < 1 || (oneNum + zeroNum + minusOneNum) < selectNum || (oneNum + zeroNum + minusOneNum) > 2 * Math.pow(10, 9)) return; int maxValue = 0; int restSelect = selectNum; if (restSelect != 0) { if (oneNum <= restSelect) { for (int oneCnt = 0; oneCnt < oneNum; oneCnt++) { maxValue++; } restSelect -= oneNum; } else { for (int oneCnt = 0; oneCnt < restSelect; oneCnt++) { maxValue++; } restSelect = 0; } } if (restSelect != 0) { if (zeroNum <= restSelect) { restSelect -= zeroNum; } else { restSelect -= restSelect; } } if (restSelect != 0) { if (minusOneNum <= restSelect) { for (int minusOneCnt = 0; minusOneCnt < minusOneNum; minusOneCnt++) { maxValue--; } restSelect -= minusOneNum; } else { for (int minusOneCnt = 0; minusOneCnt < restSelect; minusOneCnt++) { maxValue--; } restSelect -= restSelect; } } System.out.println(maxValue); } catch (Exception e) { e.printStackTrace(); } finally { stdIn.close(); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 2, 13, 13, 17, 30, 4, 18, 18, 13, 13, 2, 13, 17, 14, 2, 2, 2, 13, 13, 13, 17, 30, 4, 18, 18, 13, 13, 2, 13, 17, 30, 4, 18, 18, 13, 13, 2, 2, 13, 17, 2, 40, 17, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 97, 5 ], [ 97, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 14, 17 ], [ 17, 18 ], [ 18, 19 ], [ 8, 20 ], [ 20, 21 ], [ 20, 22 ], [ 22, 23 ], [ 23, 24 ], [ 22, 25 ], [ 25, 26 ], [ 26, 27 ], [ 8, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 30, 33 ], [ 33, 34 ], [ 34, 35 ], [ 8, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 38, 41 ], [ 41, 42 ], [ 42, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 46, 47 ], [ 46, 48 ], [ 45, 49 ], [ 44, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 51, 56 ], [ 56, 57 ], [ 56, 58 ], [ 44, 59 ], [ 59, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 60, 66 ], [ 59, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 70, 71 ], [ 70, 72 ], [ 68, 73 ], [ 73, 74 ], [ 73, 75 ], [ 59, 76 ], [ 76, 77 ], [ 77, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 77, 82 ], [ 82, 83 ], [ 83, 84 ], [ 83, 85 ], [ 82, 86 ], [ 86, 87 ], [ 87, 88 ], [ 86, 89 ], [ 89, 90 ], [ 90, 91 ], [ 90, 92 ], [ 89, 93 ], [ 6, 94 ], [ 94, 95 ], [ 0, 96 ], [ 96, 97 ], [ 96, 98 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }\n}", "Main", "public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int N = Integer.parseInt(sc.next());", "N", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int N2 = Integer.parseInt(sc.next());", "N2", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int N3 = Integer.parseInt(sc.next());", "N3", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "int N4 = Integer.parseInt(sc.next());", "N4", "Integer.parseInt(sc.next())", "Integer.parseInt", "Integer", "sc.next()", "sc.next", "sc", "if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }", "N4-N <= 0", "N4-N", "N4", "N", "0", "{\n \tSystem.out.println(N4*1);\n }", "System.out.println(N4*1)", "System.out.println", "System.out", "System", "System.out", "N4*1", "N4", "1", "if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }", "(N4-N) - N2 <= 0", "(N4-N) - N2", "(N4-N)", "N4", "N", "N2", "0", "{\n \tSystem.out.println(N*1);\n }", "System.out.println(N*1)", "System.out.println", "System.out", "System", "System.out", "N*1", "N", "1", "{\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }", "System.out.println(N*1 + (-1 * ((N4-N) - N2)))", "System.out.println", "System.out", "System", "System.out", "N*1 + (-1 * ((N4-N) - N2))", "N*1", "N", "1", "(-1 * ((N4-N) - N2))", "-1", "1", "((N4-N) - N2)", "(N4-N)", "N4", "N", "N2", "String[] args", "args", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }\n}", "public class Main {\n public static void main(String[] args ) throws Exception {\n Scanner sc = new Scanner(System.in);\n int N = Integer.parseInt(sc.next());\n int N2 = Integer.parseInt(sc.next());\n int N3 = Integer.parseInt(sc.next());\n int N4 = Integer.parseInt(sc.next());\n if(N4-N <= 0) {\n \tSystem.out.println(N4*1);\n } else if((N4-N) - N2 <= 0) {\n \tSystem.out.println(N*1);\n } else {\n \tSystem.out.println(N*1 + (-1 * ((N4-N) - N2)));\n }\n\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args ) throws Exception { Scanner sc = new Scanner(System.in); int N = Integer.parseInt(sc.next()); int N2 = Integer.parseInt(sc.next()); int N3 = Integer.parseInt(sc.next()); int N4 = Integer.parseInt(sc.next()); if(N4-N <= 0) { System.out.println(N4*1); } else if((N4-N) - N2 <= 0) { System.out.println(N*1); } else { System.out.println(N*1 + (-1 * ((N4-N) - N2))); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 4, 18, 18, 13, 13, 13, 14, 2, 13, 2, 13, 13, 4, 18, 18, 13, 13, 13, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 69, 5 ], [ 69, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 36, 41 ], [ 32, 42 ], [ 42, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 45, 47 ], [ 42, 48 ], [ 48, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 48, 53 ], [ 42, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 54, 59 ], [ 59, 60 ], [ 59, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 6, 66 ], [ 66, 67 ], [ 0, 68 ], [ 68, 69 ], [ 68, 70 ] ]
[ "import java.util.Scanner;\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }\n}", "Main", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }", "main", "{\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "if(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));", "K<=A", "K", "A", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));", "K <= A+B", "K", "A+B", "A", "B", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "System.out.println(A-(K-A-B))", "System.out.println", "System.out", "System", "System.out", "A-(K-A-B)", "A", "(K-A-B)", "K-A-B", "K", "A", "B", "String[] args", "args", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }\n}", "public class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int A = sc.nextInt();\n int B = sc.nextInt();\n int C = sc.nextInt();\n int K = sc.nextInt();\n \n \tif(K<=A) System.out.println(K);\n \telse if(K <= A+B) System.out.println(A);\n \telse System.out.println(A-(K-A-B));\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); if(K<=A) System.out.println(K); else if(K <= A+B) System.out.println(A); else System.out.println(A-(K-A-B)); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 0, 18, 13, 17, 4, 18, 13, 0, 18, 13, 17, 4, 18, 13, 0, 18, 13, 17, 4, 18, 13, 41, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 18, 13, 17, 30, 0, 13, 18, 13, 17, 0, 13, 18, 13, 17, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 18, 13, 17, 30, 0, 13, 18, 13, 17, 30, 0, 13, 17, 14, 2, 13, 18, 13, 17, 30, 0, 13, 18, 13, 17, 0, 13, 18, 13, 17, 30, 0, 13, 13, 0, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 121, 5 ], [ 121, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 8, 16 ], [ 16, 17 ], [ 17, 18 ], [ 17, 19 ], [ 16, 20 ], [ 20, 21 ], [ 21, 22 ], [ 8, 23 ], [ 23, 24 ], [ 24, 25 ], [ 24, 26 ], [ 23, 27 ], [ 27, 28 ], [ 28, 29 ], [ 8, 30 ], [ 30, 31 ], [ 31, 32 ], [ 31, 33 ], [ 30, 34 ], [ 34, 35 ], [ 35, 36 ], [ 8, 37 ], [ 37, 38 ], [ 37, 39 ], [ 39, 40 ], [ 40, 41 ], [ 8, 42 ], [ 42, 43 ], [ 43, 44 ], [ 8, 45 ], [ 45, 46 ], [ 45, 47 ], [ 8, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 51, 52 ], [ 51, 53 ], [ 48, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 57, 58 ], [ 57, 59 ], [ 54, 60 ], [ 60, 61 ], [ 60, 62 ], [ 62, 63 ], [ 62, 64 ], [ 48, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 65, 69 ], [ 69, 70 ], [ 69, 71 ], [ 8, 72 ], [ 72, 73 ], [ 73, 74 ], [ 73, 75 ], [ 75, 76 ], [ 75, 77 ], [ 72, 78 ], [ 78, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 81, 83 ], [ 72, 84 ], [ 84, 85 ], [ 85, 86 ], [ 85, 87 ], [ 8, 88 ], [ 88, 89 ], [ 89, 90 ], [ 89, 91 ], [ 91, 92 ], [ 91, 93 ], [ 88, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 97, 98 ], [ 97, 99 ], [ 94, 100 ], [ 100, 101 ], [ 100, 102 ], [ 102, 103 ], [ 102, 104 ], [ 88, 105 ], [ 105, 106 ], [ 106, 107 ], [ 106, 108 ], [ 105, 109 ], [ 109, 110 ], [ 109, 111 ], [ 8, 112 ], [ 112, 113 ], [ 113, 114 ], [ 114, 115 ], [ 114, 116 ], [ 112, 117 ], [ 6, 118 ], [ 118, 119 ], [ 0, 120 ], [ 120, 121 ], [ 120, 122 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a[] = new int[3];", "a", "new int[3]", "3", "a[0] = sc.nextInt()", "a[0]", "a", "0", "sc.nextInt()", "sc.nextInt", "sc", "a[1] = sc.nextInt()", "a[1]", "a", "1", "sc.nextInt()", "sc.nextInt", "sc", "a[2] = sc.nextInt()", "a[2]", "a", "2", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "sc.close()", "sc.close", "sc", "long sum = 0;", "sum", "0", "if (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}", "K >= a[0]", "K", "a[0]", "a", "0", "{\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t}", "sum += a[0]", "sum", "a[0]", "a", "0", "K -= a[0]", "K", "a[0]", "a", "0", "{\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}", "sum += K", "sum", "K", "K = 0", "K", "0", "if (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}", "K >= a[1]", "K", "a[1]", "a", "1", "{\n\t\t\tK -= a[1];\n\t\t}", "K -= a[1]", "K", "a[1]", "a", "1", "{\n\t\t\tK = 0;\n\t\t}", "K = 0", "K", "0", "if (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}", "K >= a[2]", "K", "a[2]", "a", "2", "{\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t}", "sum -= a[2]", "sum", "a[2]", "a", "2", "K -= a[2]", "K", "a[2]", "a", "2", "{\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}", "sum -= K", "sum", "K", "K = 0", "K", "0", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a[] = new int[3];\n\t\ta[0] = sc.nextInt();\n\t\ta[1] = sc.nextInt();\n\t\ta[2] = sc.nextInt();\n\t\tint K = sc.nextInt();\n\t\tsc.close();\n\t\tlong sum = 0;\n\t\tif (K >= a[0]) {\n\t\t\tsum += a[0];\n\t\t\tK -= a[0];\n\t\t} else {\n\t\t\tsum += K;\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[1]) {\n\t\t\tK -= a[1];\n\t\t} else {\n\t\t\tK = 0;\n\t\t}\n\t\tif (K >= a[2]) {\n\t\t\tsum -= a[2];\n\t\t\tK -= a[2];\n\t\t} else {\n\t\t\tsum -= K;\n\t\t\tK = 0;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a[] = new int[3]; a[0] = sc.nextInt(); a[1] = sc.nextInt(); a[2] = sc.nextInt(); int K = sc.nextInt(); sc.close(); long sum = 0; if (K >= a[0]) { sum += a[0]; K -= a[0]; } else { sum += K; K = 0; } if (K >= a[1]) { K -= a[1]; } else { K = 0; } if (K >= a[2]) { sum -= a[2]; K -= a[2]; } else { sum -= K; K = 0; } System.out.println(sum); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 2, 13, 13, 41, 13, 2, 13, 13, 14, 2, 13, 13, 4, 18, 18, 13, 13, 13, 14, 2, 13, 13, 4, 18, 18, 13, 13, 13, 14, 2, 13, 13, 4, 18, 18, 13, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 85, 11 ], [ 85, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 15, 17 ], [ 14, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 21, 22 ], [ 14, 23 ], [ 23, 24 ], [ 23, 25 ], [ 25, 26 ], [ 26, 27 ], [ 14, 28 ], [ 28, 29 ], [ 28, 30 ], [ 30, 31 ], [ 31, 32 ], [ 14, 33 ], [ 33, 34 ], [ 33, 35 ], [ 35, 36 ], [ 36, 37 ], [ 14, 38 ], [ 38, 39 ], [ 38, 40 ], [ 40, 41 ], [ 40, 42 ], [ 14, 43 ], [ 43, 44 ], [ 43, 45 ], [ 45, 46 ], [ 45, 47 ], [ 14, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 48, 52 ], [ 52, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 52, 57 ], [ 48, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 62, 63 ], [ 63, 64 ], [ 64, 65 ], [ 64, 66 ], [ 62, 67 ], [ 58, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 72, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 72, 77 ], [ 77, 78 ], [ 78, 79 ], [ 78, 80 ], [ 77, 81 ], [ 12, 82 ], [ 82, 83 ], [ 0, 84 ], [ 84, 85 ], [ 84, 86 ] ]
[ "/* package codechef; // don't place package name! */\n\nimport java.util.*;\nimport java.lang.*;\nimport java.io.*;\n\n/* Name of the class has to be \"Main\" only if the class is public. */\npublic class Main\n{\n public static void main (String[] args) throws java.lang.Exception\n {\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }\n}", "import java.util.*;", "util.*", "java", "import java.lang.*;", "lang.*", "java", "import java.io.*;", "io.*", "java", "public class Main\n{\n public static void main (String[] args) throws java.lang.Exception\n {\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }\n}", "Main", "public static void main (String[] args) throws java.lang.Exception\n {\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }", "main", "{\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }", "Scanner s = new Scanner(System.in);", "s", "new Scanner(System.in)", "int a = s.nextInt();", "a", "s.nextInt()", "s.nextInt", "s", "int b = s.nextInt();", "b", "s.nextInt()", "s.nextInt", "s", "int c = s.nextInt();", "c", "s.nextInt()", "s.nextInt", "s", "int k = s.nextInt();", "k", "s.nextInt()", "s.nextInt", "s", "int x = a+b;", "x", "a+b", "a", "b", "int y = x+c;", "y", "x+c", "x", "c", "if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);", "k<a", "k", "a", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);", "k < x", "k", "x", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "if(k<=y)\n System.out.println(a+x-k);", "k<=y", "k", "y", "System.out.println(a+x-k)", "System.out.println", "System.out", "System", "System.out", "a+x-k", "a+x", "a", "x", "k", "String[] args", "args", "public class Main\n{\n public static void main (String[] args) throws java.lang.Exception\n {\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }\n}", "public class Main\n{\n public static void main (String[] args) throws java.lang.Exception\n {\n // your code goes here\n Scanner s = new Scanner(System.in);\n int a = s.nextInt();\n int b = s.nextInt();\n int c = s.nextInt();\n int k = s.nextInt();\n int x = a+b;\n int y = x+c;\n if(k<a)\n System.out.println(k);\n else if(k < x)\n System.out.println(a);\n else if(k<=y)\n System.out.println(a+x-k);\n }\n}", "Main" ]
/* package codechef; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; /* Name of the class has to be "Main" only if the class is public. */ public class Main { public static void main (String[] args) throws java.lang.Exception { // your code goes here Scanner s = new Scanner(System.in); int a = s.nextInt(); int b = s.nextInt(); int c = s.nextInt(); int k = s.nextInt(); int x = a+b; int y = x+c; if(k<a) System.out.println(k); else if(k < x) System.out.println(a); else if(k<=y) System.out.println(a+x-k); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 13, 13, 14, 2, 2, 13, 13, 13, 30, 4, 18, 13, 13, 30, 4, 18, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 23, 13, 23, 13, 6, 13, 41, 13, 12, 13, 30, 0, 13, 20, 23, 13, 12, 13, 30, 0, 18, 36, 13, 20, 23, 13, 12, 13, 30, 4, 18, 13, 12, 13, 30, 4, 18, 13, 13, 23, 13, 6, 13, 41, 13, 41, 13, 20, 17, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 23, 13, 12, 13, 30, 14, 2, 13, 40, 17, 37, 20, 14, 2, 13, 13, 30, 0, 13, 17, 38, 5, 13, 30, 37, 20, 30, 0, 13, 4, 18, 13, 13, 14, 2, 13, 17, 29, 40, 17, 29, 18, 13, 40, 13, 12, 13, 30, 41, 13, 4, 13, 42, 4, 13, 13, 0, 13, 4, 13, 41, 13, 17, 14, 2, 13, 17, 30, 0, 13, 40, 17, 0, 13, 4, 13, 41, 13, 17, 42, 40, 4, 13, 13, 30, 14, 2, 2, 13, 17, 2, 13, 17, 37, 20, 0, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 13, 29, 2, 13, 13, 12, 13, 30, 29, 2, 2, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 40, 17, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], [ 13, 15 ], [ 0, 16 ], [ 16, 17 ], [ 16, 18 ], [ 0, 19 ], [ 19, 20 ], [ 19, 21 ], [ 0, 22 ], [ 22, 23 ], [ 22, 24 ], [ 0, 25 ], [ 25, 26 ], [ 25, 27 ], [ 0, 28 ], [ 28, 29 ], [ 28, 30 ], [ 0, 31 ], [ 31, 32 ], [ 31, 33 ], [ 0, 34 ], [ 326, 35 ], [ 326, 36 ], [ 36, 37 ], [ 36, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 41, 42 ], [ 41, 43 ], [ 38, 44 ], [ 44, 45 ], [ 44, 46 ], [ 46, 47 ], [ 46, 48 ], [ 38, 49 ], [ 49, 50 ], [ 49, 51 ], [ 38, 52 ], [ 52, 53 ], [ 52, 54 ], [ 38, 55 ], [ 55, 56 ], [ 55, 57 ], [ 38, 58 ], [ 58, 59 ], [ 59, 60 ], [ 58, 61 ], [ 58, 62 ], [ 58, 63 ], [ 38, 64 ], [ 64, 65 ], [ 65, 66 ], [ 36, 67 ], [ 67, 68 ], [ 326, 69 ], [ 69, 70 ], [ 69, 71 ], [ 71, 72 ], [ 71, 73 ], [ 73, 74 ], [ 74, 75 ], [ 74, 76 ], [ 76, 77 ], [ 77, 78 ], [ 73, 79 ], [ 79, 80 ], [ 79, 81 ], [ 81, 82 ], [ 82, 83 ], [ 73, 84 ], [ 84, 85 ], [ 84, 86 ], [ 86, 87 ], [ 87, 88 ], [ 73, 89 ], [ 89, 90 ], [ 89, 91 ], [ 91, 92 ], [ 92, 93 ], [ 73, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 94, 98 ], [ 98, 99 ], [ 99, 100 ], [ 100, 101 ], [ 99, 102 ], [ 94, 103 ], [ 103, 104 ], [ 104, 105 ], [ 105, 106 ], [ 105, 107 ], [ 104, 108 ], [ 103, 109 ], [ 109, 110 ], [ 110, 111 ], [ 111, 112 ], [ 110, 113 ], [ 103, 114 ], [ 114, 115 ], [ 115, 116 ], [ 116, 117 ], [ 115, 118 ], [ 118, 119 ], [ 118, 120 ], [ 120, 121 ], [ 121, 122 ], [ 121, 123 ], [ 120, 124 ], [ 71, 125 ], [ 125, 126 ], [ 71, 127 ], [ 127, 128 ], [ 71, 129 ], [ 129, 130 ], [ 326, 131 ], [ 131, 132 ], [ 131, 133 ], [ 133, 134 ], [ 131, 135 ], [ 135, 136 ], [ 135, 137 ], [ 137, 138 ], [ 138, 139 ], [ 138, 140 ], [ 135, 141 ], [ 141, 142 ], [ 131, 143 ], [ 143, 144 ], [ 143, 145 ], [ 145, 146 ], [ 146, 147 ], [ 147, 148 ], [ 147, 149 ], [ 146, 150 ], [ 143, 151 ], [ 151, 152 ], [ 131, 153 ], [ 153, 154 ], [ 153, 155 ], [ 155, 156 ], [ 156, 157 ], [ 157, 158 ], [ 131, 159 ], [ 159, 160 ], [ 159, 161 ], [ 161, 162 ], [ 162, 163 ], [ 163, 164 ], [ 162, 165 ], [ 159, 166 ], [ 166, 167 ], [ 326, 168 ], [ 168, 169 ], [ 168, 170 ], [ 170, 171 ], [ 168, 172 ], [ 172, 173 ], [ 172, 174 ], [ 168, 176 ], [ 176, 177 ], [ 168, 178 ], [ 178, 179 ], [ 168, 180 ], [ 180, 181 ], [ 180, 182 ], [ 182, 183 ], [ 183, 184 ], [ 184, 185 ], [ 184, 186 ], [ 183, 187 ], [ 180, 188 ], [ 188, 189 ], [ 168, 190 ], [ 190, 191 ], [ 190, 192 ], [ 192, 193 ], [ 193, 194 ], [ 194, 195 ], [ 194, 196 ], [ 196, 197 ], [ 193, 198 ], [ 198, 199 ], [ 192, 200 ], [ 200, 201 ], [ 201, 202 ], [ 201, 203 ], [ 200, 204 ], [ 204, 205 ], [ 205, 206 ], [ 205, 207 ], [ 204, 208 ], [ 208, 209 ], [ 209, 210 ], [ 209, 211 ], [ 211, 212 ], [ 212, 213 ], [ 208, 214 ], [ 214, 215 ], [ 215, 216 ], [ 215, 217 ], [ 217, 218 ], [ 218, 219 ], [ 217, 220 ], [ 204, 221 ], [ 221, 222 ], [ 222, 223 ], [ 222, 224 ], [ 221, 225 ], [ 225, 226 ], [ 226, 227 ], [ 192, 228 ], [ 228, 229 ], [ 229, 230 ], [ 229, 231 ], [ 231, 232 ], [ 168, 233 ], [ 233, 234 ], [ 233, 235 ], [ 235, 236 ], [ 236, 237 ], [ 236, 238 ], [ 238, 239 ], [ 235, 240 ], [ 240, 241 ], [ 241, 242 ], [ 241, 243 ], [ 240, 244 ], [ 244, 245 ], [ 244, 246 ], [ 246, 247 ], [ 235, 248 ], [ 248, 249 ], [ 248, 250 ], [ 235, 251 ], [ 251, 252 ], [ 252, 253 ], [ 252, 254 ], [ 251, 255 ], [ 255, 256 ], [ 256, 257 ], [ 256, 258 ], [ 258, 259 ], [ 255, 260 ], [ 260, 261 ], [ 260, 262 ], [ 262, 263 ], [ 235, 264 ], [ 264, 265 ], [ 264, 266 ], [ 235, 267 ], [ 267, 268 ], [ 268, 269 ], [ 269, 270 ], [ 269, 271 ], [ 267, 272 ], [ 272, 273 ], [ 273, 274 ], [ 274, 275 ], [ 275, 276 ], [ 275, 277 ], [ 274, 278 ], [ 278, 279 ], [ 278, 280 ], [ 273, 281 ], [ 281, 282 ], [ 272, 283 ], [ 283, 284 ], [ 283, 285 ], [ 272, 286 ], [ 286, 287 ], [ 286, 288 ], [ 288, 289 ], [ 288, 290 ], [ 272, 291 ], [ 291, 292 ], [ 291, 293 ], [ 293, 294 ], [ 235, 295 ], [ 295, 296 ], [ 296, 297 ], [ 296, 298 ], [ 168, 299 ], [ 299, 300 ], [ 299, 301 ], [ 301, 302 ], [ 302, 303 ], [ 306, 304 ], [ 316, 305 ], [ 313, 306 ], [ 306, 307 ], [ 307, 308 ], [ 307, 309 ], [ 306, 310 ], [ 310, 311 ], [ 310, 312 ], [ 313, 313 ], [ 313, 314 ], [ 313, 315 ], [ 316, 316 ], [ 316, 317 ], [ 316, 318 ], [ 306, 319 ], [ 319, 320 ], [ 319, 321 ], [ 321, 322 ], [ 299, 323 ], [ 323, 324 ], [ 0, 325 ], [ 325, 326 ], [ 325, 327 ] ]
[ "import java.io.OutputStream;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.OutputStream;\nimport java.io.PrintWriter;\nimport java.io.BufferedWriter;\nimport java.io.Writer;\nimport java.io.OutputStreamWriter;\nimport java.util.InputMismatchException;\nimport java.io.IOException;\nimport java.io.InputStream;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n *\n * @author sumit\n */\npublic class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }\n\n }\n\n static class OutputWriter {\n private final PrintWriter writer;\n\n public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }\n\n public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }\n\n public void close() {\n writer.close();\n }\n\n public void printLine(int i) {\n writer.println(i);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}\n", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "import java.io.BufferedWriter;", "BufferedWriter", "java.io", "import java.io.Writer;", "Writer", "java.io", "import java.io.OutputStreamWriter;", "OutputStreamWriter", "java.io", "import java.util.InputMismatchException;", "InputMismatchException", "java.util", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }\n\n }\n\n static class OutputWriter {\n private final PrintWriter writer;\n\n public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }\n\n public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }\n\n public void close() {\n writer.close();\n }\n\n public void printLine(int i) {\n writer.println(i);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "Main", "public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "InputReader in = new InputReader(inputStream);", "in", "new InputReader(inputStream)", "OutputWriter out = new OutputWriter(outputStream);", "out", "new OutputWriter(outputStream)", "BEasyLinearProgramming solver = new BEasyLinearProgramming();", "solver", "new BEasyLinearProgramming()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }\n\n }", "BEasyLinearProgramming", "public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }", "solve", "{\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }", "int a = in.nextInt();", "a", "in.nextInt()", "in.nextInt", "in", "int b = in.nextInt();", "b", "in.nextInt()", "in.nextInt", "in", "int c = in.nextInt();", "c", "in.nextInt()", "in.nextInt", "in", "int k = in.nextInt();", "k", "in.nextInt()", "in.nextInt", "in", "if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }", "a >= k", "a", "k", "{\n out.printLine(k);\n }", "out.printLine(k)", "out.printLine", "out", "k", "if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }", "a + b >= k", "a + b", "a", "b", "k", "{\n out.printLine(a);\n }", "out.printLine(a)", "out.printLine", "out", "a", "{\n out.printLine(a - (k - a - b));\n }", "out.printLine(a - (k - a - b))", "out.printLine", "out", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "int testNumber", "testNumber", "InputReader in", "in", "OutputWriter out", "out", "static class OutputWriter {\n private final PrintWriter writer;\n\n public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }\n\n public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }\n\n public void close() {\n writer.close();\n }\n\n public void printLine(int i) {\n writer.println(i);\n }\n\n }", "OutputWriter", "private final PrintWriter writer;", "writer", "public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }", "OutputWriter", "{\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }", "writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)))", "writer", "new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)))", "OutputStream outputStream", "outputStream", "public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }", "OutputWriter", "{\n this.writer = new PrintWriter(writer);\n }", "this.writer = new PrintWriter(writer)", "this.writer", "this", "this.writer", "new PrintWriter(writer)", "Writer writer", "writer", "public void close() {\n writer.close();\n }", "close", "{\n writer.close();\n }", "writer.close()", "writer.close", "writer", "public void printLine(int i) {\n writer.println(i);\n }", "printLine", "{\n writer.println(i);\n }", "writer.println(i)", "writer.println", "writer", "i", "int i", "i", "static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }", "InputReader", "private InputStream stream;", "stream", "private byte[] buf = new byte[1024];", "buf", "new byte[1024]", "1024", "private int curChar;", "curChar", "private int numChars;", "numChars", "public InputReader(InputStream stream) {\n this.stream = stream;\n }", "InputReader", "{\n this.stream = stream;\n }", "this.stream = stream", "this.stream", "this", "this.stream", "stream", "InputStream stream", "stream", "public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }", "read", "{\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }", "if (numChars == -1)\n throw new InputMismatchException();", "numChars == -1", "numChars", "-1", "1", "throw new InputMismatchException();", "new InputMismatchException()", "if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }", "curChar >= numChars", "curChar", "numChars", "{\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }", "curChar = 0", "curChar", "0", "try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }", "catch (IOException e) {\n throw new InputMismatchException();\n }", "IOException e", "{\n throw new InputMismatchException();\n }", "throw new InputMismatchException();", "new InputMismatchException()", "{\n numChars = stream.read(buf);\n }", "numChars = stream.read(buf)", "numChars", "stream.read(buf)", "stream.read", "stream", "buf", "if (numChars <= 0)\n return -1;", "numChars <= 0", "numChars", "0", "return -1;", "-1", "1", "return buf[curChar++];", "buf[curChar++]", "buf", "curChar++", "curChar", "public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }", "nextInt", "{\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }", "int c = read();", "c", "read()", "read", "while (isSpaceChar(c))\n c = read();", "isSpaceChar(c)", "isSpaceChar", "c", "c = read()", "c", "read()", "read", "int sgn = 1;", "sgn", "1", "if (c == '-') {\n sgn = -1;\n c = read();\n }", "c == '-'", "c", "'-'", "{\n sgn = -1;\n c = read();\n }", "sgn = -1", "sgn", "-1", "1", "c = read()", "c", "read()", "read", "int res = 0;", "res", "0", "do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));", "!isSpaceChar(c)", "isSpaceChar(c)", "isSpaceChar", "c", "{\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n }", "if (c < '0' || c > '9')\n throw new InputMismatchException();", "c < '0' || c > '9'", "c < '0'", "c", "'0'", "c > '9'", "c", "'9'", "throw new InputMismatchException();", "new InputMismatchException()", "res *= 10", "res", "10", "res += c & 15", "res", "c & 15", "c", "15", "c = read()", "c", "read()", "read", "return res * sgn;", "res * sgn", "res", "sgn", "public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "isSpaceChar", "{\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == '\\t'", "c == '\\r'", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == ' '", "c", "' '", "c == '\\n'", "c", "'\\n'", "c == '\\r'", "c", "'\\r'", "c == '\\t'", "c", "'\\t'", "c == -1", "c", "-1", "1", "int c", "c", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }\n\n }\n\n static class OutputWriter {\n private final PrintWriter writer;\n\n public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }\n\n public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }\n\n public void close() {\n writer.close();\n }\n\n public void printLine(int i) {\n writer.println(i);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n OutputWriter out = new OutputWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, OutputWriter out) {\n int a = in.nextInt();\n int b = in.nextInt();\n int c = in.nextInt();\n int k = in.nextInt();\n if (a >= k) {\n out.printLine(k);\n } else if (a + b >= k) {\n out.printLine(a);\n } else {\n out.printLine(a - (k - a - b));\n }\n }\n\n }\n\n static class OutputWriter {\n private final PrintWriter writer;\n\n public OutputWriter(OutputStream outputStream) {\n writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));\n }\n\n public OutputWriter(Writer writer) {\n this.writer = new PrintWriter(writer);\n }\n\n public void close() {\n writer.close();\n }\n\n public void printLine(int i) {\n writer.println(i);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new InputMismatchException();\n\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new InputMismatchException();\n }\n if (numChars <= 0)\n return -1;\n }\n\n return buf[curChar++];\n }\n\n public int nextInt() {\n int c = read();\n\n while (isSpaceChar(c))\n c = read();\n\n int sgn = 1;\n\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n\n int res = 0;\n\n do {\n if (c < '0' || c > '9')\n throw new InputMismatchException();\n\n res *= 10;\n res += c & 15;\n\n c = read();\n } while (!isSpaceChar(c));\n\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "Main" ]
import java.io.OutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.io.PrintWriter; import java.io.BufferedWriter; import java.io.Writer; import java.io.OutputStreamWriter; import java.util.InputMismatchException; import java.io.IOException; import java.io.InputStream; /** * Built using CHelper plug-in * Actual solution is at the top * * @author sumit */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; InputReader in = new InputReader(inputStream); OutputWriter out = new OutputWriter(outputStream); BEasyLinearProgramming solver = new BEasyLinearProgramming(); solver.solve(1, in, out); out.close(); } static class BEasyLinearProgramming { public void solve(int testNumber, InputReader in, OutputWriter out) { int a = in.nextInt(); int b = in.nextInt(); int c = in.nextInt(); int k = in.nextInt(); if (a >= k) { out.printLine(k); } else if (a + b >= k) { out.printLine(a); } else { out.printLine(a - (k - a - b)); } } } static class OutputWriter { private final PrintWriter writer; public OutputWriter(OutputStream outputStream) { writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream))); } public OutputWriter(Writer writer) { this.writer = new PrintWriter(writer); } public void close() { writer.close(); } public void printLine(int i) { writer.println(i); } } static class InputReader { private InputStream stream; private byte[] buf = new byte[1024]; private int curChar; private int numChars; public InputReader(InputStream stream) { this.stream = stream; } public int read() { if (numChars == -1) throw new InputMismatchException(); if (curChar >= numChars) { curChar = 0; try { numChars = stream.read(buf); } catch (IOException e) { throw new InputMismatchException(); } if (numChars <= 0) return -1; } return buf[curChar++]; } public int nextInt() { int c = read(); while (isSpaceChar(c)) c = read(); int sgn = 1; if (c == '-') { sgn = -1; c = read(); } int res = 0; do { if (c < '0' || c > '9') throw new InputMismatchException(); res *= 10; res += c & 15; c = read(); } while (!isSpaceChar(c)); return res * sgn; } public boolean isSpaceChar(int c) { return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1; } } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 12, 13, 30, 0, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 14, 2, 13, 13, 0, 13, 13, 14, 2, 2, 13, 13, 2, 2, 13, 13, 13, 0, 13, 13, 0, 13, 2, 13, 2, 2, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 4, 8 ], [ 8, 9 ], [ 8, 10 ], [ 10, 11 ], [ 11, 12 ], [ 11, 13 ], [ 10, 14 ], [ 14, 15 ], [ 14, 16 ], [ 16, 17 ], [ 17, 18 ], [ 10, 19 ], [ 19, 20 ], [ 19, 21 ], [ 21, 22 ], [ 22, 23 ], [ 10, 24 ], [ 24, 25 ], [ 24, 26 ], [ 26, 27 ], [ 27, 28 ], [ 10, 29 ], [ 29, 30 ], [ 29, 31 ], [ 31, 32 ], [ 32, 33 ], [ 10, 34 ], [ 34, 35 ], [ 10, 36 ], [ 36, 37 ], [ 37, 38 ], [ 37, 39 ], [ 36, 40 ], [ 40, 41 ], [ 40, 42 ], [ 36, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 44, 48 ], [ 48, 49 ], [ 49, 50 ], [ 49, 51 ], [ 48, 52 ], [ 43, 53 ], [ 53, 54 ], [ 53, 55 ], [ 43, 56 ], [ 56, 57 ], [ 56, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 61, 62 ], [ 61, 63 ], [ 60, 64 ], [ 10, 65 ], [ 65, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 65, 70 ], [ 8, 71 ], [ 71, 72 ] ]
[ "import java.util.*;\n\nclass Main {\n private static Scanner sc;\n\n public static void main(final String[] args) {\n sc = new Scanner(System.in);\n long a = sc.nextLong(),b = sc.nextLong(),c = sc.nextLong(),k = sc.nextLong(),ans;\n if(k <= a) ans = k;\n else if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);\n System.out.println(ans);\n }\n}\n\n\n\n\n\n", "import java.util.*;", "util.*", "java", "class Main {\n private static Scanner sc;\n\n public static void main(final String[] args) {\n sc = new Scanner(System.in);\n long a = sc.nextLong(),b = sc.nextLong(),c = sc.nextLong(),k = sc.nextLong(),ans;\n if(k <= a) ans = k;\n else if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);\n System.out.println(ans);\n }\n}", "Main", "private static Scanner sc;", "sc", "public static void main(final String[] args) {\n sc = new Scanner(System.in);\n long a = sc.nextLong(),b = sc.nextLong(),c = sc.nextLong(),k = sc.nextLong(),ans;\n if(k <= a) ans = k;\n else if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);\n System.out.println(ans);\n }", "main", "{\n sc = new Scanner(System.in);\n long a = sc.nextLong(),b = sc.nextLong(),c = sc.nextLong(),k = sc.nextLong(),ans;\n if(k <= a) ans = k;\n else if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);\n System.out.println(ans);\n }", "sc = new Scanner(System.in)", "sc", "new Scanner(System.in)", "long a = sc.nextLong()", "a", "sc.nextLong()", "sc.nextLong", "sc", "b = sc.nextLong()", "b", "sc.nextLong()", "sc.nextLong", "sc", "c = sc.nextLong()", "c", "sc.nextLong()", "sc.nextLong", "sc", "k = sc.nextLong()", "k", "sc.nextLong()", "sc.nextLong", "sc", "ans;", "ans", "if(k <= a) ans = k;\n else if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);", "k <= a", "k", "a", "ans = k", "ans", "k", "if(k > a && k-a <= b) ans = a;\n else ans = a - (k-a-b);", "k > a && k-a <= b", "k > a", "k", "a", "k-a <= b", "k-a", "k", "a", "b", "ans = a", "ans", "a", "ans = a - (k-a-b)", "ans", "a - (k-a-b)", "a", "(k-a-b)", "k-a-b", "k", "a", "b", "System.out.println(ans)", "System.out.println", "System.out", "System", "System.out", "ans", "final String[] args", "args" ]
import java.util.*; class Main { private static Scanner sc; public static void main(final String[] args) { sc = new Scanner(System.in); long a = sc.nextLong(),b = sc.nextLong(),c = sc.nextLong(),k = sc.nextLong(),ans; if(k <= a) ans = k; else if(k > a && k-a <= b) ans = a; else ans = a - (k-a-b); System.out.println(ans); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 14, 2, 13, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 29, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 73, 5 ], [ 73, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 33, 35 ], [ 32, 36 ], [ 36, 37 ], [ 37, 38 ], [ 38, 39 ], [ 39, 40 ], [ 39, 41 ], [ 37, 42 ], [ 36, 43 ], [ 8, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 47, 48 ], [ 47, 49 ], [ 44, 50 ], [ 50, 51 ], [ 51, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 51, 56 ], [ 50, 57 ], [ 8, 58 ], [ 58, 59 ], [ 59, 60 ], [ 60, 61 ], [ 60, 62 ], [ 58, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 66, 67 ], [ 66, 68 ], [ 65, 69 ], [ 6, 70 ], [ 70, 71 ], [ 0, 72 ], [ 72, 73 ], [ 72, 74 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }\n\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\n public static void main(String[] args) {\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }\n\n}", "Main", "public static void main(String[] args) {\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }", "main", "{\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }", "@SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int a = sc.nextInt();", "a", "sc.nextInt()", "sc.nextInt", "sc", "int b = sc.nextInt();", "b", "sc.nextInt()", "sc.nextInt", "sc", "int c = sc.nextInt();", "c", "sc.nextInt()", "sc.nextInt", "sc", "int k = sc.nextInt();", "k", "sc.nextInt()", "sc.nextInt", "sc", "if (k <= a) {\n System.out.println(k);\n return;\n }", "k <= a", "k", "a", "{\n System.out.println(k);\n return;\n }", "System.out.println(k)", "System.out.println", "System.out", "System", "System.out", "k", "return;", "if (k <= a + b) {\n System.out.println(a);\n return;\n }", "k <= a + b", "k", "a + b", "a", "b", "{\n System.out.println(a);\n return;\n }", "System.out.println(a)", "System.out.println", "System.out", "System", "System.out", "a", "return;", "System.out.println(a - (k - a - b))", "System.out.println", "System.out", "System", "System.out", "a - (k - a - b)", "a", "(k - a - b)", "k - a - b", "k", "a", "b", "String[] args", "args", "public class Main {\n\n public static void main(String[] args) {\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }\n\n}", "public class Main {\n\n public static void main(String[] args) {\n @SuppressWarnings(\"resource\")\n Scanner sc = new Scanner(System.in);\n int a = sc.nextInt();\n int b = sc.nextInt();\n int c = sc.nextInt();\n int k = sc.nextInt();\n if (k <= a) {\n System.out.println(k);\n return;\n }\n if (k <= a + b) {\n System.out.println(a);\n return;\n }\n System.out.println(a - (k - a - b));\n }\n\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { @SuppressWarnings("resource") Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); int c = sc.nextInt(); int k = sc.nextInt(); if (k <= a) { System.out.println(k); return; } if (k <= a + b) { System.out.println(a); return; } System.out.println(a - (k - a - b)); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 0, 13, 13, 30, 0, 13, 17, 14, 2, 13, 17, 30, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 30, 0, 13, 13, 0, 13, 17, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 102, 5 ], [ 102, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 36, 37 ], [ 36, 38 ], [ 35, 39 ], [ 39, 40 ], [ 40, 41 ], [ 40, 42 ], [ 39, 43 ], [ 43, 44 ], [ 43, 45 ], [ 35, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 50, 52 ], [ 8, 53 ], [ 53, 54 ], [ 54, 55 ], [ 54, 56 ], [ 53, 57 ], [ 53, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 58, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 58, 66 ], [ 66, 67 ], [ 67, 68 ], [ 67, 69 ], [ 8, 70 ], [ 70, 71 ], [ 71, 72 ], [ 71, 73 ], [ 70, 74 ], [ 70, 75 ], [ 75, 76 ], [ 76, 77 ], [ 76, 78 ], [ 75, 79 ], [ 79, 80 ], [ 80, 81 ], [ 80, 82 ], [ 79, 83 ], [ 83, 84 ], [ 83, 85 ], [ 75, 86 ], [ 86, 87 ], [ 87, 88 ], [ 87, 89 ], [ 86, 90 ], [ 90, 91 ], [ 90, 92 ], [ 8, 93 ], [ 93, 94 ], [ 94, 95 ], [ 95, 96 ], [ 95, 97 ], [ 93, 98 ], [ 6, 99 ], [ 99, 100 ], [ 0, 101 ], [ 101, 102 ], [ 101, 103 ] ]
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}\n}", "Main", "public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}", "main", "{\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}", "Scanner scan = new Scanner(System.in);", "scan", "new Scanner(System.in)", "int a = scan.nextInt();", "a", "scan.nextInt()", "scan.nextInt", "scan", "int b = scan.nextInt();", "b", "scan.nextInt()", "scan.nextInt", "scan", "int c = scan.nextInt();", "c", "scan.nextInt()", "scan.nextInt", "scan", "int k = scan.nextInt();", "k", "scan.nextInt()", "scan.nextInt", "scan", "int sum = 0;", "sum", "0", "if(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}", "a <= k", "a", "k", "{\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}", "k -= a", "k", "a", "sum += a", "sum", "a", "{\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}", "sum += k", "sum", "k", "k = 0", "k", "0", "if(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}", "k == 0", "k", "0", "{\n\n\t\t}", "if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}", "b <= k", "b", "k", "{\n\t\t\tk -= b;\n\t\t}", "k -= b", "k", "b", "{\n\t\t\tk = 0;\n\t\t}", "k = 0", "k", "0", "if(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}", "k == 0", "k", "0", "{\n\n\t\t}", "if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}", "c <= k", "c", "k", "{\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}", "k -= c", "k", "c", "sum -= c", "sum", "c", "{\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}", "sum -= k", "sum", "k", "k = 0", "k", "0", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}\n}", "public class Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\n\t\tint a = scan.nextInt();\n\t\tint b = scan.nextInt();\n\t\tint c = scan.nextInt();\n\t\tint k = scan.nextInt();\n\t\tint sum = 0;\n\n\t\tif(a <= k) {\n\t\t\tk -= a;\n\t\t\tsum += a;\n\t\t}else {\n\t\t\tsum += k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(b <= k){\n\t\t\tk -= b;\n\t\t}else {\n\t\t\tk = 0;\n\t\t}\n\n\t\tif(k == 0) {\n\n\t\t}else if(c <= k){\n\t\t\tk -= c;\n\t\t\tsum -= c;\n\t\t}else {\n\t\t\tsum -= k;\n\t\t\tk = 0;\n\t\t}\n\n\t\tSystem.out.println(sum);\n\t}\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int a = scan.nextInt(); int b = scan.nextInt(); int c = scan.nextInt(); int k = scan.nextInt(); int sum = 0; if(a <= k) { k -= a; sum += a; }else { sum += k; k = 0; } if(k == 0) { }else if(b <= k){ k -= b; }else { k = 0; } if(k == 0) { }else if(c <= k){ k -= c; sum -= c; }else { sum -= k; k = 0; } System.out.println(sum); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 14, 2, 2, 13, 13, 2, 2, 13, 13, 13, 30, 4, 18, 18, 13, 13, 13, 14, 2, 13, 13, 30, 4, 18, 18, 13, 13, 13, 30, 4, 18, 18, 13, 13, 2, 13, 2, 2, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 76, 5 ], [ 76, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 33, 34 ], [ 34, 35 ], [ 34, 36 ], [ 33, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 37, 41 ], [ 32, 42 ], [ 42, 43 ], [ 43, 44 ], [ 44, 45 ], [ 45, 46 ], [ 45, 47 ], [ 43, 48 ], [ 32, 49 ], [ 49, 50 ], [ 50, 51 ], [ 50, 52 ], [ 49, 53 ], [ 53, 54 ], [ 54, 55 ], [ 55, 56 ], [ 56, 57 ], [ 56, 58 ], [ 54, 59 ], [ 49, 60 ], [ 60, 61 ], [ 61, 62 ], [ 62, 63 ], [ 63, 64 ], [ 63, 65 ], [ 61, 66 ], [ 66, 67 ], [ 66, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 68, 72 ], [ 6, 73 ], [ 73, 74 ], [ 0, 75 ], [ 75, 76 ], [ 75, 77 ] ]
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }\n}", "import java.util.Scanner;", "Scanner", "java.util", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }\n}", "Main", "public static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A=sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B=sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C=sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K=sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }", "K>=A&&A+B>=K", "K>=A", "K", "A", "A+B>=K", "A+B", "A", "B", "K", "{\n System.out.println(A);\n }", "System.out.println(A)", "System.out.println", "System.out", "System", "System.out", "A", "if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }", "K<A", "K", "A", "{\n System.out.println(K);\n }", "System.out.println(K)", "System.out.println", "System.out", "System", "System.out", "K", "{\n System.out.println(A-(K-A-B));\n }", "System.out.println(A-(K-A-B))", "System.out.println", "System.out", "System", "System.out", "A-(K-A-B)", "A", "(K-A-B)", "K-A-B", "K", "A", "B", "String[] args", "args", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }\n}", "public class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n int A=sc.nextInt();\n int B=sc.nextInt();\n int C=sc.nextInt();\n int K=sc.nextInt();\n if(K>=A&&A+B>=K){\n System.out.println(A);\n }else if(K<A){\n System.out.println(K);\n }else{\n System.out.println(A-(K-A-B));\n }\n }\n}", "Main" ]
import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); int A=sc.nextInt(); int B=sc.nextInt(); int C=sc.nextInt(); int K=sc.nextInt(); if(K>=A&&A+B>=K){ System.out.println(A); }else if(K<A){ System.out.println(K); }else{ System.out.println(A-(K-A-B)); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 0, 13, 8, 2, 13, 13, 13, 13, 0, 13, 13, 14, 2, 13, 17, 30, 0, 13, 13, 14, 2, 13, 17, 30, 0, 13, 8, 2, 13, 13, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 76, 5 ], [ 76, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [ 14, 15 ], [ 15, 16 ], [ 8, 17 ], [ 17, 18 ], [ 17, 19 ], [ 19, 20 ], [ 20, 21 ], [ 8, 22 ], [ 22, 23 ], [ 22, 24 ], [ 24, 25 ], [ 25, 26 ], [ 8, 27 ], [ 27, 28 ], [ 27, 29 ], [ 29, 30 ], [ 30, 31 ], [ 8, 32 ], [ 32, 33 ], [ 32, 34 ], [ 8, 35 ], [ 35, 36 ], [ 35, 37 ], [ 37, 38 ], [ 38, 39 ], [ 38, 40 ], [ 37, 41 ], [ 37, 42 ], [ 8, 43 ], [ 43, 44 ], [ 43, 45 ], [ 8, 46 ], [ 46, 47 ], [ 47, 48 ], [ 47, 49 ], [ 46, 50 ], [ 50, 51 ], [ 51, 52 ], [ 51, 53 ], [ 8, 54 ], [ 54, 55 ], [ 55, 56 ], [ 55, 57 ], [ 54, 58 ], [ 58, 59 ], [ 59, 60 ], [ 59, 61 ], [ 61, 62 ], [ 62, 63 ], [ 62, 64 ], [ 61, 65 ], [ 61, 66 ], [ 8, 67 ], [ 67, 68 ], [ 68, 69 ], [ 69, 70 ], [ 69, 71 ], [ 67, 72 ], [ 6, 73 ], [ 73, 74 ], [ 0, 75 ], [ 75, 76 ], [ 75, 77 ] ]
[ "import java.util.*;\npublic class Main {\n\tpublic static void main(String arg[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}\n}", "import java.util.*;", "util.*", "java", "public class Main {\n\tpublic static void main(String arg[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}\n}", "Main", "public static void main(String arg[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}", "main", "{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}", "Scanner sc = new Scanner(System.in);", "sc", "new Scanner(System.in)", "int A = sc.nextInt();", "A", "sc.nextInt()", "sc.nextInt", "sc", "int B = sc.nextInt();", "B", "sc.nextInt()", "sc.nextInt", "sc", "int C = sc.nextInt();", "C", "sc.nextInt()", "sc.nextInt", "sc", "int K = sc.nextInt();", "K", "sc.nextInt()", "sc.nextInt", "sc", "int res = 0;", "res", "0", "res += (K >= A) ? A : K", "res", "(K >= A) ? A : K", "(K >= A)", "K", "A", "A", "K", "K -= A", "K", "A", "if(K > 0) {\n\t\t\tK-= B;\n\t\t}", "K > 0", "K", "0", "{\n\t\t\tK-= B;\n\t\t}", "K-= B", "K", "B", "if(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}", "K > 0", "K", "0", "{\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}", "res -= (K >= C) ? C : K", "res", "(K >= C) ? C : K", "(K >= C)", "K", "C", "C", "K", "System.out.println(res)", "System.out.println", "System.out", "System", "System.out", "res", "String arg[]", "arg", "public class Main {\n\tpublic static void main(String arg[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}\n}", "public class Main {\n\tpublic static void main(String arg[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint A = sc.nextInt();\n\t\tint B = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint K = sc.nextInt();\n\n\t\tint res = 0;\n\n\t\tres += (K >= A) ? A : K;\n\t\tK -= A;\n\t\tif(K > 0) {\n\t\t\tK-= B;\n\t\t}\n\t\tif(K > 0) {\n\t\t\tres -= (K >= C) ? C : K;\n\t\t}\n\t\tSystem.out.println(res);\n\t}\n}", "Main" ]
import java.util.*; public class Main { public static void main(String arg[]) { Scanner sc = new Scanner(System.in); int A = sc.nextInt(); int B = sc.nextInt(); int C = sc.nextInt(); int K = sc.nextInt(); int res = 0; res += (K >= A) ? A : K; K -= A; if(K > 0) { K-= B; } if(K > 0) { res -= (K >= C) ? C : K; } System.out.println(res); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 18, 13, 13, 41, 13, 18, 13, 13, 41, 13, 20, 41, 13, 20, 41, 13, 20, 4, 18, 13, 17, 13, 13, 4, 18, 13, 23, 13, 6, 13, 12, 13, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 41, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 17, 14, 2, 13, 13, 30, 0, 13, 13, 4, 18, 18, 13, 13, 13, 23, 13, 23, 13, 23, 13, 6, 13, 41, 13, 41, 13, 20, 17, 41, 13, 41, 13, 12, 13, 30, 0, 18, 36, 13, 13, 23, 13, 12, 13, 30, 14, 2, 13, 40, 17, 37, 20, 14, 2, 13, 13, 30, 0, 13, 17, 38, 5, 13, 30, 37, 20, 30, 0, 13, 4, 18, 13, 13, 14, 2, 13, 17, 29, 40, 17, 29, 18, 13, 40, 13, 12, 13, 30, 41, 13, 4, 13, 42, 4, 13, 13, 0, 13, 4, 13, 41, 13, 17, 14, 2, 13, 17, 30, 0, 13, 40, 17, 0, 13, 4, 13, 41, 13, 17, 42, 40, 4, 13, 13, 30, 0, 13, 17, 0, 13, 2, 13, 17, 0, 13, 4, 13, 29, 2, 13, 13, 12, 13, 30, 29, 2, 2, 2, 2, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 17, 2, 13, 40, 17, 23, 13, 10, 6, 13 ]
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 293, 14 ], [ 293, 15 ], [ 15, 16 ], [ 15, 17 ], [ 17, 18 ], [ 18, 19 ], [ 18, 20 ], [ 20, 21 ], [ 20, 22 ], [ 17, 23 ], [ 23, 24 ], [ 23, 25 ], [ 25, 26 ], [ 25, 27 ], [ 17, 28 ], [ 28, 29 ], [ 28, 30 ], [ 17, 31 ], [ 31, 32 ], [ 31, 33 ], [ 17, 34 ], [ 34, 35 ], [ 34, 36 ], [ 17, 37 ], [ 37, 38 ], [ 38, 39 ], [ 37, 40 ], [ 37, 41 ], [ 37, 42 ], [ 17, 43 ], [ 43, 44 ], [ 44, 45 ], [ 15, 46 ], [ 46, 47 ], [ 293, 48 ], [ 48, 49 ], [ 48, 50 ], [ 50, 51 ], [ 50, 52 ], [ 52, 53 ], [ 53, 54 ], [ 53, 55 ], [ 55, 56 ], [ 56, 57 ], [ 52, 58 ], [ 58, 59 ], [ 58, 60 ], [ 60, 61 ], [ 61, 62 ], [ 52, 63 ], [ 63, 64 ], [ 63, 65 ], [ 65, 66 ], [ 66, 67 ], [ 52, 68 ], [ 68, 69 ], [ 68, 70 ], [ 70, 71 ], [ 71, 72 ], [ 52, 73 ], [ 73, 74 ], [ 73, 75 ], [ 52, 76 ], [ 76, 77 ], [ 77, 78 ], [ 77, 79 ], [ 76, 80 ], [ 80, 81 ], [ 81, 82 ], [ 81, 83 ], [ 80, 84 ], [ 84, 85 ], [ 84, 86 ], [ 52, 87 ], [ 87, 88 ], [ 88, 89 ], [ 88, 90 ], [ 87, 91 ], [ 91, 92 ], [ 92, 93 ], [ 92, 94 ], [ 91, 95 ], [ 95, 96 ], [ 95, 97 ], [ 52, 98 ], [ 98, 99 ], [ 99, 100 ], [ 99, 101 ], [ 98, 102 ], [ 102, 103 ], [ 103, 104 ], [ 103, 105 ], [ 52, 106 ], [ 106, 107 ], [ 107, 108 ], [ 107, 109 ], [ 106, 110 ], [ 110, 111 ], [ 111, 112 ], [ 111, 113 ], [ 52, 114 ], [ 114, 115 ], [ 115, 116 ], [ 115, 117 ], [ 114, 118 ], [ 118, 119 ], [ 119, 120 ], [ 119, 121 ], [ 118, 122 ], [ 122, 123 ], [ 122, 124 ], [ 52, 125 ], [ 125, 126 ], [ 126, 127 ], [ 126, 128 ], [ 125, 129 ], [ 129, 130 ], [ 130, 131 ], [ 130, 132 ], [ 52, 133 ], [ 133, 134 ], [ 134, 135 ], [ 135, 136 ], [ 135, 137 ], [ 133, 138 ], [ 50, 139 ], [ 139, 140 ], [ 50, 141 ], [ 141, 142 ], [ 50, 143 ], [ 143, 144 ], [ 293, 145 ], [ 145, 146 ], [ 145, 147 ], [ 147, 148 ], [ 145, 149 ], [ 149, 150 ], [ 149, 151 ], [ 145, 153 ], [ 153, 154 ], [ 145, 155 ], [ 155, 156 ], [ 145, 157 ], [ 157, 158 ], [ 157, 159 ], [ 159, 160 ], [ 160, 161 ], [ 161, 162 ], [ 161, 163 ], [ 160, 164 ], [ 157, 165 ], [ 165, 166 ], [ 145, 167 ], [ 167, 168 ], [ 167, 169 ], [ 169, 170 ], [ 170, 171 ], [ 171, 172 ], [ 171, 173 ], [ 173, 174 ], [ 170, 175 ], [ 175, 176 ], [ 169, 177 ], [ 177, 178 ], [ 178, 179 ], [ 178, 180 ], [ 177, 181 ], [ 181, 182 ], [ 182, 183 ], [ 182, 184 ], [ 181, 185 ], [ 185, 186 ], [ 186, 187 ], [ 186, 188 ], [ 188, 189 ], [ 189, 190 ], [ 185, 191 ], [ 191, 192 ], [ 192, 193 ], [ 192, 194 ], [ 194, 195 ], [ 195, 196 ], [ 194, 197 ], [ 181, 198 ], [ 198, 199 ], [ 199, 200 ], [ 199, 201 ], [ 198, 202 ], [ 202, 203 ], [ 203, 204 ], [ 169, 205 ], [ 205, 206 ], [ 206, 207 ], [ 206, 208 ], [ 208, 209 ], [ 145, 210 ], [ 210, 211 ], [ 210, 212 ], [ 212, 213 ], [ 213, 214 ], [ 213, 215 ], [ 215, 216 ], [ 212, 217 ], [ 217, 218 ], [ 218, 219 ], [ 218, 220 ], [ 217, 221 ], [ 221, 222 ], [ 221, 223 ], [ 223, 224 ], [ 212, 225 ], [ 225, 226 ], [ 225, 227 ], [ 212, 228 ], [ 228, 229 ], [ 229, 230 ], [ 229, 231 ], [ 228, 232 ], [ 232, 233 ], [ 233, 234 ], [ 233, 235 ], [ 235, 236 ], [ 232, 237 ], [ 237, 238 ], [ 237, 239 ], [ 239, 240 ], [ 212, 241 ], [ 241, 242 ], [ 241, 243 ], [ 212, 244 ], [ 244, 245 ], [ 245, 246 ], [ 246, 247 ], [ 246, 248 ], [ 244, 249 ], [ 249, 250 ], [ 250, 251 ], [ 250, 252 ], [ 249, 253 ], [ 253, 254 ], [ 253, 255 ], [ 255, 256 ], [ 255, 257 ], [ 249, 258 ], [ 258, 259 ], [ 258, 260 ], [ 260, 261 ], [ 212, 262 ], [ 262, 263 ], [ 263, 264 ], [ 263, 265 ], [ 145, 266 ], [ 266, 267 ], [ 266, 268 ], [ 268, 269 ], [ 269, 270 ], [ 273, 271 ], [ 283, 272 ], [ 280, 273 ], [ 273, 274 ], [ 274, 275 ], [ 274, 276 ], [ 273, 277 ], [ 277, 278 ], [ 277, 279 ], [ 280, 280 ], [ 280, 281 ], [ 280, 282 ], [ 283, 283 ], [ 283, 284 ], [ 283, 285 ], [ 273, 286 ], [ 286, 287 ], [ 286, 288 ], [ 288, 289 ], [ 266, 290 ], [ 290, 291 ], [ 0, 292 ], [ 292, 293 ], [ 292, 294 ] ]
[ "import java.io.IOException;\nimport java.io.InputStream;\nimport java.io.OutputStream;\nimport java.io.PrintWriter;\n\n/**\n * Built using CHelper plug-in\n * Actual solution is at the top\n *\n * @author Spandan Mishra\n */\npublic class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }\n\n public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}\n", "import java.io.IOException;", "IOException", "java.io", "import java.io.InputStream;", "InputStream", "java.io", "import java.io.OutputStream;", "OutputStream", "java.io", "import java.io.PrintWriter;", "PrintWriter", "java.io", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }\n\n public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "Main", "public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "main", "{\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }", "InputStream inputStream = System.in;", "inputStream", "System.in", "System", "System.in", "OutputStream outputStream = System.out;", "outputStream", "System.out", "System", "System.out", "InputReader in = new InputReader(inputStream);", "in", "new InputReader(inputStream)", "PrintWriter out = new PrintWriter(outputStream);", "out", "new PrintWriter(outputStream)", "BEasyLinearProgramming solver = new BEasyLinearProgramming();", "solver", "new BEasyLinearProgramming()", "solver.solve(1, in, out)", "solver.solve", "solver", "1", "in", "out", "out.close()", "out.close", "out", "String[] args", "args", "static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }\n\n }", "BEasyLinearProgramming", "public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }", "solve", "{\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }", "long a = in.readLong()", "a", "in.readLong()", "in.readLong", "in", "b = in.readLong()", "b", "in.readLong()", "in.readLong", "in", "c = in.readLong()", "c", "in.readLong()", "in.readLong", "in", "k = in.readLong();", "k", "in.readLong()", "in.readLong", "in", "long sum = 0;", "sum", "0", "if (k <= a) {\n sum += k;\n k = 0;\n }", "k <= a", "k", "a", "{\n sum += k;\n k = 0;\n }", "sum += k", "sum", "k", "k = 0", "k", "0", "if (k > a) {\n sum += a;\n k -= a;\n }", "k > a", "k", "a", "{\n sum += a;\n k -= a;\n }", "sum += a", "sum", "a", "k -= a", "k", "a", "if (k <= b) {\n k = 0;\n }", "k <= b", "k", "b", "{\n k = 0;\n }", "k = 0", "k", "0", "if (k > b) {\n k -= b;\n }", "k > b", "k", "b", "{\n k -= b;\n }", "k -= b", "k", "b", "if (k <= c) {\n sum -= k;\n k = 0;\n }", "k <= c", "k", "c", "{\n sum -= k;\n k = 0;\n }", "sum -= k", "sum", "k", "k = 0", "k", "0", "if (k > c) {\n sum -= k;\n\n }", "k > c", "k", "c", "{\n sum -= k;\n\n }", "sum -= k", "sum", "k", "System.out.println(sum)", "System.out.println", "System.out", "System", "System.out", "sum", "int testNumber", "testNumber", "InputReader in", "in", "PrintWriter out", "out", "static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }\n\n public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }", "InputReader", "private InputStream stream;", "stream", "private byte[] buf = new byte[1024];", "buf", "new byte[1024]", "1024", "private int curChar;", "curChar", "private int numChars;", "numChars", "public InputReader(InputStream stream) {\n this.stream = stream;\n }", "InputReader", "{\n this.stream = stream;\n }", "this.stream = stream", "this.stream", "this", "this.stream", "stream", "InputStream stream", "stream", "public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }", "read", "{\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }", "if (numChars == -1)\n throw new RuntimeException();", "numChars == -1", "numChars", "-1", "1", "throw new RuntimeException();", "new RuntimeException()", "if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }", "curChar >= numChars", "curChar", "numChars", "{\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }", "curChar = 0", "curChar", "0", "try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }", "catch (IOException e) {\n throw new RuntimeException();\n }", "IOException e", "{\n throw new RuntimeException();\n }", "throw new RuntimeException();", "new RuntimeException()", "{\n numChars = stream.read(buf);\n }", "numChars = stream.read(buf)", "numChars", "stream.read(buf)", "stream.read", "stream", "buf", "if (numChars <= 0)\n return -1;", "numChars <= 0", "numChars", "0", "return -1;", "-1", "1", "return buf[curChar++];", "buf[curChar++]", "buf", "curChar++", "curChar", "public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }", "readLong", "{\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }", "int c = read();", "c", "read()", "read", "while (isSpaceChar(c))\n c = read();", "isSpaceChar(c)", "isSpaceChar", "c", "c = read()", "c", "read()", "read", "int sgn = 1;", "sgn", "1", "if (c == '-') {\n sgn = -1;\n c = read();\n }", "c == '-'", "c", "'-'", "{\n sgn = -1;\n c = read();\n }", "sgn = -1", "sgn", "-1", "1", "c = read()", "c", "read()", "read", "long res = 0;", "res", "0", "do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));", "!isSpaceChar(c)", "isSpaceChar(c)", "isSpaceChar", "c", "{\n res *= 10;\n res += c - '0';\n c = read();\n }", "res *= 10", "res", "10", "res += c - '0'", "res", "c - '0'", "c", "'0'", "c = read()", "c", "read()", "read", "return res * sgn;", "res * sgn", "res", "sgn", "public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "isSpaceChar", "{\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }", "return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == '\\t'", "c == '\\r'", "c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1", "c == ' '", "c", "' '", "c == '\\n'", "c", "'\\n'", "c == '\\r'", "c", "'\\r'", "c == '\\t'", "c", "'\\t'", "c == -1", "c", "-1", "1", "int c", "c", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }\n\n public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "public class Main {\n public static void main(String[] args) {\n InputStream inputStream = System.in;\n OutputStream outputStream = System.out;\n InputReader in = new InputReader(inputStream);\n PrintWriter out = new PrintWriter(outputStream);\n BEasyLinearProgramming solver = new BEasyLinearProgramming();\n solver.solve(1, in, out);\n out.close();\n }\n\n static class BEasyLinearProgramming {\n public void solve(int testNumber, InputReader in, PrintWriter out) {\n long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong();\n long sum = 0;\n if (k <= a) {\n sum += k;\n k = 0;\n }\n if (k > a) {\n sum += a;\n k -= a;\n }\n if (k <= b) {\n k = 0;\n }\n\n if (k > b) {\n k -= b;\n }\n\n if (k <= c) {\n sum -= k;\n k = 0;\n }\n\n if (k > c) {\n sum -= k;\n\n }\n\n\n System.out.println(sum);\n }\n\n }\n\n static class InputReader {\n private InputStream stream;\n private byte[] buf = new byte[1024];\n private int curChar;\n private int numChars;\n\n public InputReader(InputStream stream) {\n this.stream = stream;\n }\n\n public int read() {\n if (numChars == -1)\n throw new RuntimeException();\n if (curChar >= numChars) {\n curChar = 0;\n try {\n numChars = stream.read(buf);\n } catch (IOException e) {\n throw new RuntimeException();\n }\n if (numChars <= 0)\n return -1;\n }\n return buf[curChar++];\n }\n\n public long readLong() {\n int c = read();\n while (isSpaceChar(c))\n c = read();\n int sgn = 1;\n if (c == '-') {\n sgn = -1;\n c = read();\n }\n long res = 0;\n do {\n res *= 10;\n res += c - '0';\n c = read();\n } while (!isSpaceChar(c));\n return res * sgn;\n }\n\n public boolean isSpaceChar(int c) {\n return c == ' ' || c == '\\n' || c == '\\r' || c == '\\t' || c == -1;\n }\n\n }\n}", "Main" ]
import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.io.PrintWriter; /** * Built using CHelper plug-in * Actual solution is at the top * * @author Spandan Mishra */ public class Main { public static void main(String[] args) { InputStream inputStream = System.in; OutputStream outputStream = System.out; InputReader in = new InputReader(inputStream); PrintWriter out = new PrintWriter(outputStream); BEasyLinearProgramming solver = new BEasyLinearProgramming(); solver.solve(1, in, out); out.close(); } static class BEasyLinearProgramming { public void solve(int testNumber, InputReader in, PrintWriter out) { long a = in.readLong(), b = in.readLong(), c = in.readLong(), k = in.readLong(); long sum = 0; if (k <= a) { sum += k; k = 0; } if (k > a) { sum += a; k -= a; } if (k <= b) { k = 0; } if (k > b) { k -= b; } if (k <= c) { sum -= k; k = 0; } if (k > c) { sum -= k; } System.out.println(sum); } } static class InputReader { private InputStream stream; private byte[] buf = new byte[1024]; private int curChar; private int numChars; public InputReader(InputStream stream) { this.stream = stream; } public int read() { if (numChars == -1) throw new RuntimeException(); if (curChar >= numChars) { curChar = 0; try { numChars = stream.read(buf); } catch (IOException e) { throw new RuntimeException(); } if (numChars <= 0) return -1; } return buf[curChar++]; } public long readLong() { int c = read(); while (isSpaceChar(c)) c = read(); int sgn = 1; if (c == '-') { sgn = -1; c = read(); } long res = 0; do { res *= 10; res += c - '0'; c = read(); } while (!isSpaceChar(c)); return res * sgn; } public boolean isSpaceChar(int c) { return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1; } } }