-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJ1114.java
More file actions
46 lines (37 loc) · 1.08 KB
/
Copy pathJ1114.java
File metadata and controls
46 lines (37 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
package TIL;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
public class J1114 {
public static void main(String[] args) throws IOException {
BufferedReader buffer = new BufferedReader(new InputStreamReader(System.in));
String[] input = buffer.readLine().split(" ");
long l = Long.parseLong(input[0]);
int k = Integer.parseInt(input[1]);
int c = Integer.parseInt(input[2]);
int[] cut = new int[k];
input = buffer.readLine().split(" ");
for(int i = 0; i < k; i++){
cut[i] = Integer.parseInt(input[i]);
}
Arrays.sort(cut);
long from = 1;
long to = l;
long mid = 0;
long result =0;
long resultCut =cut[0];
//
// while(from <= to){
// mid = (from + to)/2;
//
// if(cutting != -1){
// result = mid;
// resultCut = cutting;
// to = mid-1;
// }else{
// from = mid+1;
// }
// }
}
}