I have written a Java code as below, which generates random numbers and sums them to give correct answer. However, I am also trying to generate to two false answers that are not equal to each other or the correct answer using do while statement. However, it is not working. The last do part of the java code is not being run. It is possible to have two random number ans\_wrong1 and ans\_wrong2 which are the same. 

In simple english, if ans\_wrong2 equals ans\_wrong1 OR ans\_correct, generate another random number. Continue this process until number is generated which is not equal to any of the other two numbers. Can someone spot what I am doing wrong and offer suggestion? 

Lets try to simplify the question further, because, the suggested solutions are not working.

I want t generate two random numbers that do not equal to each other or the correct answer.

Code updated - still not working

Thanks

```
int ans_correct = 8;

int ans_wrong1;
    do {
        ans_wrong1 = randomGenerator.nextInt(20);
    } while(ans_wrong1 == ans_correct);

    int ans_wrong2;
    do {
        ans_wrong2 = randomGenerator.nextInt(10);
    } while ( ans_wrong2 == ans_correct || ans_wrong2 == ans_wrong1 );

```