I have initialized an array
String s = sc.nextLine();
String[] Question = s.split(" ");
then I have this while-loop calling a method/function
while (y != x) {
analyzer anlz = new analyzer();
anlz.find(Question[y]);
y = y + 1;
}
but anlz.find(Question[y]) keeps getting a wrong mark saying that non-static variable Question cannot be referenced from a static context
and this is the function/method find(String[] q)
public String find(String[] q) throws IOException {
//content here
}
i don't know how to fix this. can someone please help me?