y=ax+b is the standard linear equation. The y intercept is b and the x intercept is -b/a. So b-b/a=5 and -b^2/a=6. Multiply each equation through by a: ab-b=5a and b^2=-6a. So b(a-1)=5a and b=5a/(a-1). Substitute this in the other equation: 25a^2/(a-1)^2=-6a. Divide through by a: 25a/(a-1)^2=-6. Multiply through by (a-1)^2: 25a=-6(a-1)^2=-6a^2+12a-6. This can be written: 6a^2+13a+6=0=(3a+2)(2a+3)=0. So a=-2/3 or -3/2. And b=2 or 3. The linear equations are y=-2x/3+2 and y=-3x/2+3. These can be written 3y+2x=6 and 2y+3x=6.