You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all, I would have assumed that a pizza with a diameter of 0 is no pizza. But even if we consider that such a pizza might exist: A pizza with a diameter of 0 couldn't possibly have a larger per-slice area than a slice of a pizza with a diameter of 16", regardless of how many slices you cut the second pizza into.
The text was updated successfully, but these errors were encountered:
The idea here is that "16 inches" is a faulty input, meaning that pizza is an error. Even a pizza with a size of 0 is bigger than a pizza with an error. It is a bit confusing, I am currently doing quite a big update to the track currently. I might rewatch this exercise, or might just remove that test case. We will see.
If the pizza is less than an inch in diameter, it might be appropriate to round down and say it’s zero inches. In that case, that pizza is still valid. The instructions should still make this clear to the student though.
The tests in the pizza-slices exercise has:
swift/exercises/concept/pizza-slices/Tests/PizzaSlicesTests/PizzaSlicesTests.swift
Lines 71 to 72 in 4dea7e2
First of all, I would have assumed that a pizza with a diameter of 0 is no pizza. But even if we consider that such a pizza might exist: A pizza with a diameter of 0 couldn't possibly have a larger per-slice area than a slice of a pizza with a diameter of 16", regardless of how many slices you cut the second pizza into.
The text was updated successfully, but these errors were encountered: