Steve D'Aprano wrote:
There's no need to set the radius and the diameter, as one is completely derived
from the other

Good point; I'm glad I submitted my code for grading. Sort of a "trick question" to ask me to add diameter and then take off points because I used it! ; )

Bill



and the transformation is cheap enough to perform on the fly as
needed.

Consider what happens if, due to a bug or an accident, you end up with a Circle
instance that says the radius is 5 and the diameter is 20. They can't *both* be
right, and

--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to