finished first version of bayes theorum