Your mistake seems to be that you're confusing the width of each pen with the width of the whole area. The formula $2w + 5l = 750$ assumes that $w$ is the width of all four pens added together, yet $4lw = a$ treats $w$ as the width of only one pen. Once you make the definition of $w$ consistent, you should get the right answer.
I assume that you have made a sketch. That is the first step to solving the problem.
Imagine making the type of enclosure described. Let the sides parallel to the fence in the middle have length $x$, and let the other two sides of the rectangle each have length $y$. Write $x$ beside the two sides and the fence in the middle that have length $x$, and write $y$ beside the two sides that have length $y$.
From the picture, we see that the amount of fencing used is $3x+2y$. if we want to make the enclosure large, itt is clear that we are best off using all the available fencing. Thus we must have $3x+2y=900$. We want to maximize the area $xy$, given that $3x+2y=900$.
Now proceed as has been suggested for similar problems. We have $y=\frac{1}{2}(900-3x)$.
So we want to maximize $f(x)=\frac{1}{2}(x)(900-3x)$.
If we want to use calculus, note that $f(x)=450x -\frac{3}{2}x^2$. So $f'(x)=450-3x$. The derivative is $0$ at $x=150$.
The maximum area is therefore $f(150)$, which is not hard to compute. I would prefer to find $y$ from $3x+2y=900$. If $x=150$ then from $3x+2y=900$ we get $y=225$. Thus the maximum area that can be enclosed is $(150)(225)$.
Remark: If we want to be very fussy (and sometimes it can be important to be), we can note that $0\le x\le 300$ (where $x=0$ and $x=300$ do not give "real" fields). Our function $f$ attains a maximum in the interval $0\le x\le 300$. But obviously $f(0)=f(300)=0$, so the maximum is not attained at an endpoint. Thus the maximum is reached at a place where $f'(x)=0$. There is only one such place, namely $x=150$, so the maximum must be reached there. Thus our calculation does yield the maximum area.
Best Answer
Let the two inside parallel walls each have length $x$. Let the sides of the rectangle perpendicular to these each have length $y$.
Then the total area enclosed is $xy$. The amount of fencing used is $4x+2y$. This is to be $900$, since it is clear that it is best to use up all the fencing.
So we want to maximize $xy$, under the constraint $4x+2y=900$.
Thus $y=450-2x$, and we want to maximize $x(450-2x)$.
Because of the physical situation, we need $x\ge 0$ and $y\ge 0$. This means $x\le 225$.
So mathematically, we want to minimize $f(x)=450x-2x^2$, where $0\le x\le 225$.
This can be done by standard tools, such as calculus or completing the square.