Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.io.*;
- import java.util.*;
- import static java.lang.Math.*;
- public class SolutionTemplate implements Runnable {
- final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE") != null;
- BufferedReader in;
- PrintWriter out;
- StringTokenizer tok = new StringTokenizer("");
- void init() throws IOException {
- if (ONLINE_JUDGE) {
- in = new BufferedReader(new InputStreamReader(System.in));
- out = new PrintWriter(System.out);
- } else {
- in = new BufferedReader(new FileReader("input.txt"));
- out = new PrintWriter("output.txt");
- }
- }
- String readString() throws IOException {
- while (!tok.hasMoreTokens()) {
- tok = new StringTokenizer(in.readLine());
- }
- return tok.nextToken();
- }
- int readInt() throws IOException {
- return Integer.parseInt(readString());
- }
- public void run() {
- try {
- long t1 = System.currentTimeMillis();
- init();
- solve();
- out.close();
- long t2 = System.currentTimeMillis();
- System.err.println("Time = " + (t2 - t1));
- } catch (Exception e) {
- e.printStackTrace(System.err);
- System.exit(-1);
- }
- }
- public static void main(String[] args) {
- new Thread(new SolutionTemplate()).start();
- }
- void solve() throws IOException {
- int a = readInt();
- int b = readInt();
- out.print(a + b);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement