a) Ta có: \(\frac{x^2-1}{x^2-4x+4}:\frac{x+1}{2-x}=\frac{\left(x-1\right)\left(x+1\right)}{\left(x-2\right)^2}\cdot\frac{2-x}{x+1}=\frac{\left(x-1\right)\left(x+1\right)\left(2-x\right)}{\left(2-x\right)^2\cdot\left(x+1\right)}=\frac{x-1}{2-x}\)
b) Ta có: \(\frac{x-2}{x-6}-\frac{x-18}{6-x}+\frac{x+2}{x-6}=\frac{x-2}{x-6}+\frac{x-18}{x-6}+\frac{x+2}{x-6}=\frac{x-2+x-18+x+2}{x-6}=\frac{3x-18}{x-6}=\frac{3\left(x-6\right)}{x-6}=3\)