Skip to content

Instantly share code, notes, and snippets.

@johncip johncip/uva-fast-io
Created May 25, 2014

Embed
What would you like to do?
Contest problem fast I/O template
/*
* Title
*/
import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Main {
static BufferedReader in = new BufferedReader(new InputStreamReader(
System.in));
static BufferedOutputStream out = new BufferedOutputStream(System.out);
static StringBuilder res = new StringBuilder();
/**
* Entry point.
*/
public static void main(String[] args) throws IOException {
String line;
while ((line = in.readLine()) != null) {
line = line.trim();
res.append(handleCase(line));
res.append('\n');
}
out.write(res.toString().getBytes());
in.close();
out.close();
}
/**
* Handles a case.
*/
static String handleCase(String line) {
return line;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.