watching a talk about something called the "gilded rose kata" so I look it up and my thoughts roughly in order are:
SellIn
field?none of this is what the exercise is actually about, which is iteratively refactoring the ugly code inside that function (er, method). but you know what I've been down this road enough times to know that iteratively refactoring code like this is likely to be a huge waste of time; you'll spend more effort preserving the almost certainly buggy behavior than you would by outright rewriting it.
the underspecification comment also applies to questions like:
SellIn
reaches 0 or at the end of day during which it was 0?SellIn
?(I don't actually care about the answers to these questions, I'm just saying that I question the value of an exercise whose explicit premise is "don't worry about the specification or the design of the points of interaction with the rest of the system, focus on improving the implementation," because frankly I think most developers need to work on the former a lot more than the latter. a spaghetti function is localized suck; imprecise specification and half-assed interface design are global problems)
@sjolsen at least it was a hardware specification and we had real hardware to test our code against, but still, good god