Bayes tank problem HW02 ICFP 2018.py