Data:
Dog 1: A
Dog 2: B

You use substitution method:
1. Solve one variable in one equation:
Solve A in frist equation:

2. Use the solution for the variable in the other equation.
Use A=15-B in the second equation:

3. Solve the variable.
Solve for B:

As you get a quadratic function, you need to use a quadratic equation:
![\begin{gathered} ax^2+bx+c=0 \\ x=\frac{-b\pm\sqrt[]{b^2-4ac}}{2a} \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/uuterq6bz1kwr2mb9jy58c523r5v4v644y.png)
![\begin{gathered} B=\frac{-(15)\pm\sqrt[]{(15)^2-4(-1)(-44)}}{2(-1)} \\ \\ B=\frac{-15\pm\sqrt[]{225-176}}{-2} \\ \\ B=\frac{-15\pm\sqrt[]{49}}{-2} \\ \\ B=(-15\pm7)/(-2) \\ \\ B_1=(-15+7)/(-2),B_2=(-15-7)/(-2) \\ \\ B_1=4 \\ B_2=11 \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/hmmv6zn2x8kqe5pswizprf6l4qah18kcsl.png)
4. Use the value of B to find the value of A:

Then, One of the dogs have 11 years and the other dog has 4 years