andrew.m.higgs
  • andrew.m.higgs
So how many of you got caught with the ceiling_test? It took me a while to figure out why my answer was 1 less than it should be. :-)
MIT 6.189 A Gentle Introduction to Programming Using Python (OCW)
  • Stacey Warren - Expert brainly.com
Hey! We 've verified this expert answer for you, click below to unlock the details :)
SOLVED
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
jamiebookeater
  • jamiebookeater
I got my questions answered at brainly.com in under 10 minutes. Go to brainly.com now for free help!
anonymous
  • anonymous
my answer is not the totally correct one and I've not figured out why - but since I'm horrible at math, I'm not surprised.
andrew.m.higgs
  • andrew.m.higgs
Yeah. Maths is definitely not my strong point....
anonymous
  • anonymous
I'm curious what approach you used to finally resolve. There are two problems with the write-up of part 2. The first is that there is no "ceiling" function. The second is that the test cases supplied explicitly use integer division.

Looking for something else?

Not the answer you are looking for? Search for more explanations.

More answers

anonymous
  • anonymous
There is a math.ceil function if you import math (http://docs.python.org/2/library/math.html) so you can use that. I had a hard time getting the order correct in the variable to get it to get the right answer when using my multiadd function.
andrew.m.higgs
  • andrew.m.higgs
Yes, as Susan says there is a math.ceil function. I simply divided by 19.0 so it returns a float. It took quite a while for me to spot that I was exactly 1 out. :-)

Looking for something else?

Not the answer you are looking for? Search for more explanations.