-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathhayfeast.java
More file actions
50 lines (37 loc) · 1.13 KB
/
hayfeast.java
File metadata and controls
50 lines (37 loc) · 1.13 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
47
48
49
50
import java.io.*;
import java.util.*;
/**
* Created by supersteve on 1/14/18.
*/
public class hayfeast {
public static void main(String[] args) throws IOException {
// write your code here
BufferedReader f = new BufferedReader(new FileReader("bphoto.in"));
// input file name goes above
StringTokenizer st = new StringTokenizer(f.readLine());
int n = Integer.parseInt(st.nextToken());
int m = Integer.parseInt(st.nextToken());
pair[] x = new pair[n];
for(int i =0; i<n;i++){
st = new StringTokenizer(f.readLine());
pair a = new pair();
a.flavor = Integer.parseInt(st.nextToken());
a.spicy = Integer.parseInt(st.nextToken());
}
int flavorcount = 0;
int start = 0;
for(int i =0; i<n;i++){
if(flavorcount<m){
continue;
}
else{
}
}
PrintWriter out = new PrintWriter(new BufferedWriter(new FileWriter("bphoto.out")));
out.close();
}
static class pair{
int spicy;
int flavor;
}
}