Question 235566
Setup:
------------
A = Number of Rows
B = Number of Trees per row
Equation 1: {{{A*B = 126}}}
Equation 2: {{{A = B - 5}}}
Solution:
------------
Plug (B-5) into Equation 1 for A
{{{A*B = 126}}}
{{{(B-5)*B = 126}}} Rewrite the equation
{{{B^2-5B = 126}}} Set the equation to 0 by subtract 126 from both sides
{{{B^2-5B -126 = 0}}}
Find the factors of 126
The factors are: 1, 2, 3, 6, 7, 9, 14, 18 21, 42,63,126
Notice that 9 and 14 are the factors that are 5 apart and we have a -5B
So the equation can be foiled
{{{B^2-5B -126 = 0}}}
{{{B^2-5B -126 = 0 = (B+9)*(B-14)}}}
Looking at {{{(B+9)*(B-14) = 0}}} we see two solutions
{{{B + 9 = 0}}} rewritten as {{{B = -9}}}
& {{{B - 14 = 0}}} rewritten as {{{B = 14}}}
Since we can not have a negative number of trees, we will use B = 14

Now plug 14 into equation 2 for B
Equation 2: {{{A = B - 5}}}
{{{A = 14 - 5}}}
{{{A = 9}}}

Check your answer:
-------------------------
Using A = 9 & B = 14 Solve equation 1
Equation 1: {{{A*B = 126}}}
{{{14 * 9 = 126}}}
{{{126 = 126}}}