\(B=\dfrac{2+\sqrt{a}}{\sqrt{a}+1}+\dfrac{2-\sqrt{a}}{\sqrt{a}-1}\left(dkxd:a>0,a\ne1\right)\)
\(=\dfrac{\left(2+\sqrt{a}\right)\left(\sqrt{a}-1\right)+\left(2-\sqrt{a}\right)\left(\sqrt{a}+1\right)}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\)
\(=\dfrac{2\sqrt{a}-2+a-\sqrt{a}+2\sqrt{a}+2-a-\sqrt{a}}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\)
\(=\dfrac{2\sqrt{a}-\sqrt{a}+2\sqrt{a}-\sqrt{a}}{\sqrt{a^2}-1}\)
\(=\dfrac{2\sqrt{a}}{a-1}\)
\(B=\dfrac{\left(2+\sqrt{a}\right)\left(\sqrt{a}-1\right)}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}+\dfrac{\left(2-\sqrt{a}\right)\left(\sqrt{a}+1\right)}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\\ =\dfrac{2\sqrt{a}-2+a-\sqrt{a}}{a-1}+\dfrac{2\sqrt{a}+2-a-\sqrt{a}}{a-1}\\ =\dfrac{\sqrt{a}-2+a+\sqrt{a}+2-a}{a-1}=\dfrac{2\sqrt{a}}{a-1}\)
\(B=\dfrac{2+\sqrt{a}}{\sqrt{a}+1}+\dfrac{2-\sqrt{a}}{\sqrt{a}-1}\)
\(B=\dfrac{\left(2+\sqrt{a}\right)\left(\sqrt{a}-1\right)+\left(2-\sqrt{a}\right)\left(\sqrt{a}+1\right)}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\)
\(B=\dfrac{2\sqrt{a}-2+a-\sqrt{a}+2\sqrt{a}+2-a-\sqrt{a}}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\)
\(B=\dfrac{2\sqrt{a}}{\left(\sqrt{a}+1\right)\left(\sqrt{a}-1\right)}\)
\(B=\dfrac{\text{}\text{}2\sqrt{a}}{a-1}\)