p and q are integers. If p is divisible by 10^q and cannot be divisible by 10^(q + 1), what is the value of q?p being divisible by 10^q and not by 10^(q + 1) implies that the number of trailing zeros in p is exactly q (p ends with exactly q zeros).
(1) p is divisible by 2^5, but is not divisible by 2^6.
This implies that, the number of trailing zeros, q, is less than or equal to 5: \(q\leq{5}\) (since each trailing zero in p requires one 2 and one 5 in its prime factorization, this statement confirms five 2s, but the number of 5s remains unknown). Not sufficient.
(2) p is divisible by 5^6, but is not divisible by 5^7
This implies that, the number of trailing zeros, q, is less than or equal to 6: \(q\leq{6}\) (since each trailing zero in p requires one 2 and one 5 in its prime factorization, this statement confirms six 5s, but the number of 2s remains unknown). Not sufficient.
(1)+(2) We have five 2s and six 5s, which give exactly 5 trailing zeros: \(q=5\) (as the number of 2s is the limiting factor here). Sufficient.
Answer: C.