a) \(\frac{a-\sqrt{a}}{\sqrt{a}-1}=\frac{\left(a-\sqrt{a}\right)\left(\sqrt{a}+1\right)}{\left(\sqrt{a}-1\right)\left(\sqrt{a}+1\right)}=\frac{a\sqrt{a}-\sqrt{a}}{a-1}=\frac{\sqrt{a}\left(a-1\right)}{a-1}=\sqrt{a}\)
b) \(\frac{p-2\sqrt{p}}{p-\sqrt{2}}=\frac{\left(p-2\sqrt{p}\right)\left(p+\sqrt{2}\right)}{\left(p-\sqrt{2}\right)\left(p+\sqrt{2}\right)}=\frac{\left(p-2\sqrt{p}\right)\left(p+\sqrt{2}\right)}{p^2-2}\)