The ProductDistribution class has been updated to handle any non-zero number of distributions.