java.util.scanner
Using string taken from Scanner not working?
When I run the program and enter a rank & gender it yells at me and tells me it is an invalid gender. I cannot see why if I enter \"male\" into the console, it does not equal the string \"male\"?[详细]
2023-01-21 08:18 分类:问答Java Scanner Class Help
I would like to find out how to print a a certain string from an input file using a scanner. For the string to be printed the line must start with *star and the string must be surrounded by quotation[详细]
2023-01-20 14:03 分类:问答Keyboard Input In A Separate Class?
Just started learning Java a week or so ago.I have made a little Java program开发者_开发问答 that calculates the amount of reviews, and the average review rating that something has.For instance, on th[详细]
2023-01-20 01:23 分类:问答Java Scanner() to read from Array
I know you can set the input for a scanner in Java. Is it possible to feed an array to the开发者_如何学编程 scanner?Use the Arrays.toString() method on the array.[详细]
2023-01-19 15:06 分类:问答Reading a file using Java scanner
One of the lines in a java file I\'m trying to understand is as below. return new Scanner(file).useDelimiter(\"\\\\Z\").next();[详细]
2023-01-18 21:19 分类:问答Output from a file in printf
Looking for help with the following code: package pkgPeople; import java.io.File; import java.io.FileOutputStream;[详细]
2023-01-18 13:29 分类:问答Java Scanner.useDelimiter() problem with ""
I have having a problem with Java Scanner.useDelimiter() delimiting \"\". I am trying to use the Scanner to read a CSV file.The CSV have 2 column (Name, Description) and the Description field have开发[详细]
2023-01-18 08:28 分类:问答Problem with java.util.Scanner & strings
I tried to implement a simple yes/no input with java.util.Scanner. My code looks like this: public boolean ask(String quest){[详细]
2023-01-17 19:00 分类:问答Java Problems - Scanner Input and If (X == Input) Statements
I just read through seven threads related to Java Scanner issues, but none contained the answer to my problem.[详细]
2023-01-15 12:26 分类:问答How do you create an array to store regex string matches in java?
I\'m trying to take a file that store data of this form: Name=”Biscuit” LatinName=”Retrieverus Aurum”[详细]
2023-01-15 07:12 分类:问答