a: \(A=\dfrac{x+4\sqrt{x}-2}{\left(\sqrt{x}+2\right)\left(\sqrt{x}-1\right)}-\dfrac{x-1}{\left(\sqrt{x}+2\right)\left(\sqrt{x}-1\right)}-\dfrac{\sqrt{x}-2}{\sqrt{x}}\cdot\dfrac{1-1+\sqrt{x}}{1-\sqrt{x}}\)
\(=\dfrac{x+4\sqrt{x}-2-x+1}{\left(\sqrt{x}+2\right)\left(\sqrt{x}-1\right)}+\dfrac{\sqrt{x}-2}{\sqrt{x}-1}\)
\(=\dfrac{4\sqrt{x}-1+x-4}{\left(\sqrt{x}-1\right)\left(\sqrt{x}+2\right)}=\dfrac{x+4\sqrt{x}-5}{\left(\sqrt{x}-1\right)\left(\sqrt{x}+2\right)}\)
\(=\dfrac{\sqrt{x}+5}{\sqrt{x}+2}\)
b: \(B=\dfrac{x\sqrt{x}+26\sqrt{x}-19}{\left(\sqrt{x}+3\right)\left(\sqrt{x}-1\right)}-\dfrac{2x+6\sqrt{x}}{\left(\sqrt{x}-1\right)\left(\sqrt{x}+3\right)}+\dfrac{x-4\sqrt{x}+3}{\left(\sqrt{x}+3\right)\left(\sqrt{x}-1\right)}\)
\(=\dfrac{x\sqrt{x}+26\sqrt{x}-19-2x-6\sqrt{x}+x-4\sqrt{x}+3}{\left(\sqrt{x}+3\right)\left(\sqrt{x}-1\right)}\)
\(=\dfrac{x\sqrt{x}-x+16\sqrt{x}-16}{\left(\sqrt{x}+3\right)\left(\sqrt{x}-1\right)}=\dfrac{x+16}{\sqrt{x}+3}\)