Since I couldn't figure out an easy way to convert my string array into an integer array, I looked up an example for a method and here is what I ended up with:
private int[] convert(String string) {
int number[] = new int[string.length()];
for (int i = 0; i < string.length(); i++) {
number[i] = Integer.parseInt(string[i]); // error here
}
return number;
}
parseInt requires a string which is what string[i] is but the error tells me "The type of the expression must be an array type but it resolved to String"
I can't figure out what is the problem with my code.
EDIT: I'm an idiot. Thanks all it was obvious.