Skip to content

Instantly share code, notes, and snippets.

@erinwan
Created April 1, 2015 17:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save erinwan/3f8c7d5a0756ba38945e to your computer and use it in GitHub Desktop.
Save erinwan/3f8c7d5a0756ba38945e to your computer and use it in GitHub Desktop.
prompt user for input scanner in Java
Scanner scanner = new Scanner(System.in);
System.out.println("Please enter input");
String input = scanner.nextLine();
scanner.close();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment