While reviewing someone’s solution to the Calculator Conundrum exercise in the C# track, I noticed that the “exemplar” solution uses a
SimpleOperation class, which is defined in a separate source file. I suppose its purpose is that it throws a divide-by-zero exception, which the student-implemented
SimpleCalculator method is meant to catch.
Unfortunately, there is absolutely no mention of this class’s existence in the requirements, the test file, or even in the
Hints.md file. The student I was reviewing didn’t use it, nor did I, nor did any of the other posted solutions I looked at.
It strikes me that if there is any demogogic intent in supplying this class, its usage should be specified in the requirements. If there isn’t any reason for it, the “exemplar” solution should be modified to reflect the more straightforward approach that most people seem to be taking. After all, implementing arithmetic operations is pretty simple, even for beginners.