Ok, thank you very much for your help, I can now get the number with the strategy you have helped me with, I've got it converting to an int also that i can add to a running total.
Type: Posts; User: connorlm3
Ok, thank you very much for your help, I can now get the number with the strategy you have helped me with, I've got it converting to an int also that i can add to a running total.
when i print the string there, the output gives me this [Mary, F, 1234]
if (nextLine.contains(genName)) {
String[] numbers =...
Ok i see how the split method works now, if i make a string like String tosplit = new String(","); and i use it in split, it just puts spaces in the string after the commas? I dont see how that could...
Would something like this work.
if(nextLine.contains(genName)) {
int length = nextLine.length();
...
arrays? where are arrays coming into this? you lost me now. and ok i found the method for the string to int conversion. still confused where arrays are coming into play at.. and if i try running my...
So in the java docs i found this
String[] split(String regex)
Splits this string around matches of the given regular expression.
Trying to understand what it means, and how to...
well how i have it set up is what im searching the file for would be like this "Mary,F" and i already have the line that contains that as a string. How does this split method work?
I have a program where a user enters a name and a gender, then the program is suppose to read through all these yob####.txt files to see if it contains that name,gender. if it does, i need to be able...