Hello, I am getting this error with my code "error: This method must return a result of type int" haven't a clue why it's happening.
int processresponse(String response){ int a; Boolean foundresponse = false; for (a = 0; a < vresponses.size(); a++) { // Check if response exists. if (vresponses.get(a) == response) { foundresponse = true; return a; } } if (foundresponse == false) { vresponses.add(response); return vresponses.size()-1; } }
Any help much appreciated.