Inverse Transform Sampling and Maximum Likelihood Estimation