Skip to content

Instantly share code, notes, and snippets.

@HituziANDO
Last active October 9, 2015 06:07
Show Gist options
  • Save HituziANDO/3450987 to your computer and use it in GitHub Desktop.
Save HituziANDO/3450987 to your computer and use it in GitHub Desktop.
Java_ConsoleInput
private static String consoleInput (String prompt) throws IOException {
if (prompt != null) {
System.out.print(prompt);
}
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
return br.readLine();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment