-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathjava_template.java
More file actions
50 lines (45 loc) · 1.46 KB
/
java_template.java
File metadata and controls
50 lines (45 loc) · 1.46 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.*;
import java.math.*;
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();
int tesCases = in.nextInt();
for(int test = 1; test <= tesCases; test += 1) {
solver.solve(test, in, out);
}
out.close();
}
static class Task {
static final int MOD = (int) (1e9 + 7);
public void solve(int testNumber, InputReader in, PrintWriter out) {
//Your code goes below
}
}
static class InputReader {
public BufferedReader take;
public StringTokenizer split;
public InputReader(InputStream stream) {
take = new BufferedReader(new InputStreamReader(stream), 10000000);
split = null;
}
public String next() {
while (split == null || !split.hasMoreTokens()) {
try {
split = new StringTokenizer(take.readLine());
}
catch (IOException e) {
throw new RuntimeException(e);
}
}
return split.nextToken();
}
public int nextInt() {
return Integer.parseInt(next());
}
}
}