Update Question.java
This commit is contained in:
parent
8d9545f86b
commit
20b3e0c598
1 changed files with 2 additions and 2 deletions
|
@ -30,13 +30,13 @@ public class Question {
|
|||
public void checkAnswer(ArrayList<DictionaryEntry> listOfCorrectQuestions, ArrayList<String>listOfAnswers, boolean isEnglish){
|
||||
if(isEnglish){
|
||||
for(int i=0; i<listOfCorrectQuestions.size();i++){
|
||||
if(listOfCorrectQuestions.get(i).getWelsh().equals(listOfAnswers.get(i))){
|
||||
if(listOfCorrectQuestions.get(i).getEnglish().equals(listOfAnswers.get(i))){
|
||||
correctAnswer++;
|
||||
}else wrongAnswer++;
|
||||
}
|
||||
}else{
|
||||
for(int i=0; i<listOfCorrectQuestions.size();i++){
|
||||
if(listOfCorrectQuestions.get(i).getEnglish().equals(listOfAnswers.get(i))){
|
||||
if(listOfCorrectQuestions.get(i).getWelsh().equals(listOfAnswers.get(i))){
|
||||
correctAnswer++;
|
||||
}else wrongAnswer++;
|
||||
}
|
||||
|
|
Reference in a new issue