Split the Array to Make Coprime Products
Two products are coprime exactly when no prime divides both, so track how far each prefix prime reaches to the right.
Two products are coprime exactly when no prime divides both, so track how far each prefix prime reaches to the right.