Step-by-step explanation:
For any rectangle the dimensions are given by:

So the perimeter (P) is given by the following equation:

And the area is:

We know that:

By substituting:

Solving for
from eq1:

Substituting into eq2:

Then:

Solving for w:

So this rectangle is a square and is shown below.