\(B=\dfrac{\sqrt{x}}{\sqrt{x}+2}.\left(\dfrac{2x+2\sqrt{x}+3-x+\sqrt{x}-1}{\left(\sqrt{x}+1\right)\left(x-\sqrt{x}+1\right)}\right)\\ =\dfrac{\sqrt{x}}{\sqrt{x}+2}.\left(\dfrac{x+3\sqrt{x}+2}{\left(\sqrt{x}+1\right)\left(x-\sqrt{x}+1\right)}\right)\)
\(=\dfrac{\sqrt{x}}{\sqrt{x}+2}.\left(\dfrac{\left(\sqrt{x}+1\right)\left(\sqrt{x}+2\right)}{\left(\sqrt{x}+1\right)\left(x-\sqrt{x}+1\right)}\right)\)
`= (sqrt x)/(x - sqrt x + 1)`