I assume and Object is something that would be in another Array? such as Book is an object?
What do I use to see if the array contains a String then?
Thank you for your help
Type: Posts; User: Noob_Programmer
I assume and Object is something that would be in another Array? such as Book is an object?
What do I use to see if the array contains a String then?
Thank you for your help
I am having some trouble searching an ArrayList to see if it contains a string.
public Book findByTitle(String title){
Book book = new Book();
int location;...
Yeah the \n changes it. I might just not use it, and use my other solution to the problem I was having. Appreciate your help anyway!
Just the number 1.
If I remove the s.useDelimiter("\n");
There is no problems, but I was told to use this to solve another problem, which is using nextLine() before a nextInt().
Exception in thread "main" java.util.InputMismatchException
at java.util.Scanner.throwFor(Unknown Source)
at java.util.Scanner.next(Unknown Source)
at java.util.Scanner.nextInt(Unknown Source)...
Hey guys I am having some trouble when I use Scanner.UseDelimeter("\n") basically I have:
Scanner s = new Scanner(System.in);
s.useDelimiter("\n");
int amount;
...