About 136,000 results
Open links in new tab
  1. How to get the user input in Java? - Stack Overflow

    Mar 13, 2011 · I attempted to create a calculator, but I can not get it to work because I don't know how to get user input. How can I get the user input in Java?

  2. java.util.scanner - How can I read input from the console using the ...

    This Scanner class comes under java.util, hence the first line of the program is import java.util.Scanner; which allows the user to read values of various types in Java.

  3. Reading a plain text file in Java - Stack Overflow

    It seems there are different ways to read and write data of files in Java. I want to read ASCII data from a file. What are the possible ways and their differences?

  4. How do I read / convert an InputStream into a String in Java?

    4771 If you have a java.io.InputStream object, how should you process that object and produce a String? Suppose I have an InputStream that contains text data, and I want to convert it to a String, so …

  5. Reading a .txt file using Scanner class in Java - Stack Overflow

    I am working on a Java program that reads a text file line-by-line, each with a number, takes each number throws it into an array, then tries and use insertion sort to sort the array. I need help w...

  6. Validating input using java.util.Scanner - Stack Overflow

    How to use java.util.Scanner to correctly read user input from System.in and act on it? (1 answer)

  7. java - Using BufferedReader to read Text File - Stack Overflow

    I'm having problems with using the BufferedReader I want to print the 6 lines of a text file: public class Reader { public static void main (String []args) throws IOException { FileReader in...

  8. java - Take a char input from the Scanner - Stack Overflow

    Dec 19, 2012 · When you read from the console via System.in, the input is typically buffered by the operating system, and only "released" to the application when the user types ENTER. So if you …

  9. java - How to parse a JSON Input stream - Stack Overflow

    With Jackson you can use a JsonParser to read one section at a time. Below is an example of code I wrote that wraps the reading of an Array of JsonObjects in an Iterator. If you just want to see an …

  10. How to read input with multiple lines in Java - Stack Overflow

    How to read input with multiple lines in Java Asked 15 years, 9 months ago Modified 6 years, 8 months ago Viewed 133k times