Definition:Quadratic Residue

Definition
Let $$p$$ be an odd prime.

Let $$a \not \equiv 0 \pmod p$$.

Then $$a$$ is a quadratic residue of $$p$$ iff $$x^2 \equiv a \pmod p$$ has a solution.

That is, iff $$\exists x \in \Z: x^2 \equiv a \pmod p$$.

Quadratic Non-Residue
If there is no such integer $$x$$ such that $$x^2 \equiv a \pmod p$$, then $$a$$ is a quadratic non-residue of $$p$$.

Quadratic Character
Any integer $$a$$ is either a quadratic residue or a quadratic non-residue of $$p$$.

Whether it is or not is known as the quadratic character of $$a$$ modulo $$p$$.

Quadratic Character of Congruent Integers
Note that if $$a \equiv b \pmod p$$ then $$x^2 \equiv a \pmod p$$ has a solution iff $$x^2 \equiv b \pmod p$$.

So congruent integers are of the same quadratic character.

Therefore it is sufficient to consider the quadratic character of the non-zero least positive residues modulo $$p$$.

Example
Take $$p = 11$$.

To list the quadratic residues of $$11$$ it is enough to work out the squares $$1^2, 2^2, \ldots, 10^2$$ modulo $$11$$.

$$ $$ $$ $$ $$ $$ $$ $$ $$ $$

So the quadratic residues of $$11$$ are $$1, 3, 4, 5, 9$$.

The quadratic non-residues of $$11$$ are therefore all the other non-zero least positive residues, that is, $$2, 6, 7, 8, 10$$.

Also see
Definition of the Legendre symbol.

Note
The case where $$a = 0$$ has been excluded from the definition, despite the fact that $$0 = 0^2$$ and so is definitely a square.

The case where $$p = 2$$ is also excluded, where the only non-zero residue $$1$$ is also a square.

The main reason for this is so that some useful results can be expressed in a convenient form.

For example, this means that the Number of Quadratic Residues of a Prime $$p$$ is always equal to $$\frac {p-1} 2$$, which is the same as the number of quadratic non-residues.