Skip to content

Instantly share code, notes, and snippets.

@idodin
Created March 11, 2020 17:23
Show Gist options
  • Save idodin/03a6057b2c1393edd9c337b32d01dd04 to your computer and use it in GitHub Desktop.
Save idodin/03a6057b2c1393edd9c337b32d01dd04 to your computer and use it in GitHub Desktop.
Competitive Programming Java Template
import java.util.*;
import java.math.*;
import java.io.*;
public class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(
new InputStreamReader(System.in)
);
StringTokenizer st = new StringTokenizer(br.readLine());
//Check if there are more tokens to read from input
boolean moreTokens = st.hasMoreTokens();
// Get next token (token is a string, use Integer.parseInt or Double.parseDouble to get int / double)
String s = st.nextToken();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment