We factorise all of them:
p(x)=x2−2x+1=(x−1)2,
q(x)=x4−1=(x2−1)(x2+1)=(x−1)(x+1)(x2+1),
r(x)=x3−2x2−5x+6=x3−x2+x−6x+6
=x2(x−1)−x(x−1)−6(x−1)
=(x−1)(x2−x−6)=(x−1)(x−3)(x+2).
Observe that HCF(p(x),q(x))=x−1 and HCF(x−1,r(x))=x−1. Hence the HCF of p(x),q(x),r(x) is x−1.