Area of square = l²
Perimeter of square = 4l
According to the question,
[tex]l^2 = 45 + 4l \\\\ l^2 - 4l - 45 = 0 \\\\ l^2 -9l+5l-45=0 \\\\ l(l-9)+5(l-9) =0 \\\\(l-9)(l+5)=0[/tex]
Using zero product property,
Either,
[tex]l-9 = 0 \\
~~~~~~l = 9[/tex]
Or,
[tex]l+5=0 \\
~~~~~~l=-5[/tex]
Since length can't be negative, the length is 9