I'm receiving a cannot resolve symbol error in my code
<p>The issue is in this block of code with the word "quote"</p>

<pre><code>if (quotesCopy.size() &gt; 20) {
    quotesCopy = new ArrayList&lt;String&gt;();
}

displayMessageTextView.setText(quote);
</code></pre>

<p>This is all of my code:</p>

<pre><code>public class MainActivity extends AppCompatActivity {

    private Button addButton;
    private TextView displayMessageTextView;
    private ArrayList&lt;String&gt; quotesCopy = new ArrayList&lt;String&gt;();
    private ArrayList&lt;String&gt; quotes = new ArrayList&lt;String&gt;();
    private Random randomGenerator = new Random();
    private int previousNumber = 0;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        quotes.add("You smart! You loyal! You're a genious!");
        quotes.add("I appreciate you");
        quotes.add("This is a major key");
        quotes.add("They will try to close the door on U, just open it");
        quotes.add("The key to more success is CoCo butter");
        quotes.add("Congratulations, you played yourself");
        quotes.add("Another one, no. Another two");
        quotes.add("I changed... a lot");
        quotes.add("They don't want you to jet ski");
        quotes.add("The key is to have every key");
        quotes.add("Almond milk + Cinnamon Toast Crunch = Major key to success");
        quotes.add("Do you see that bamboo? Ain't nothing like bamboo. Blessup");
        quotes.add("Bless up. Egg whites, Turkey bacon, Hashbrown, Water");
        quotes.add("They wanna come stress me out? Heh, bye");
        quotes.add("Lion Order");
        quotes.add("Watch your back, but when you get out of the shower dry your back, it's a cold world");
        quotes.add("Some of ya'll crabs");
        quotes.add("ANOTHA ONE");
        quotes.add("We jus seen 2 dolphins");
        quotes.add("They don't want you to win");
        quotes.add("Be A Star. Be A Superstar");
        quotes.add("I remember when I ain't have a jacuzzi");
        quotes.add("The other day the grass was brown, now it's green cuz I ain't give up");
        quotes.add("In life everyone has a choice. The key is...make a right choice");
        quotes.add("We have to get money. We have no choice. It cost money to eat");
        quotes.add("I love my bamboo trees. I love fruits. I love apples.");
        quotes.add("I told y'all this before, when you have a swimming pool do not use chlorine, use salt water");
        quotes.add("The key is: never fold");
        quotes.add("major key, get a pedicure and manicure once a week");
        quotes.add("They dont want you to be healthy");
        quotes.add("To make it thru the jungle you're gonna have to sweat");
        quotes.add("They never said winning was easy");
        quotes.add("It's important to shape up your hedges. It's like getting a haircut");
        quotes.add("LIOOOOON");
        quotes.add("To succeed, you must believe. When you believe you will succeed. ");
        quotes.add("The key to success is to have a hammock");
        quotes.add("Some people can't handle winning. I can.");
        quotes.add("They don't want you to have lunch");
        quotes.add("It's not an easy road but give thanks to the road");
        quotes.add("The key to success is to have a lot of pillows. A lot.");

        displayMessageTextView = (TextView) findViewById(R.id.displayMessageTextView);
        displayMessageTextView.setText("Press the button to generate a random quote");

        addButton = (Button) findViewById(R.id.addObjecttive);
        addButton.setOnClickListener(new View.OnClickListener() {

            @Override
            public void onClick(View v) {
                Boolean isDifferent = false;
                while (!isDifferent) {
                    int randomQuoteIndex = getRandomNumber();
                    String quote = quotes.get(randomQuoteIndex);
                    if (!quotesCopy.contains(quote)) {
                        isDifferent = true;
                        quotesCopy.add(quote);
                    }
                    if (quotesCopy.size() &gt; 20)
                        quotesCopy = new ArrayList&lt;String&gt;();
                }

                displayMessageTextView.setText(quote);
            }
        });
    }

    public int getRandomNumber() {
        int randomNumber = randomGenerator.nextInt(40);

        while (previousNumber == randomNumber) {
            randomNumber = randomGenerator.nextInt(40);
        }

        previousNumber = randomNumber;

        return randomNumber;
    }
}
</code></pre>