contestada

N = 2^p x 5^q x 7^r and 500 = 2^2 x 5^3.
The HCF of N and 500 is 2^2 x 5^2.
The LCM of N and 500 is 2^3 x 5^3 x 7.
Find p, q and r