The "on-topicness" for answers is not nearly as clear-cut as for questions (and even that has plenty of grey areas). The very first sentence, on its own, is enough to make it a valid code review: "First the good: your code provides a testable function."
Abusive answers, or answers which do nothing more than provide links, or an alternative solution without critiquing the OP code in any way, are about the only things in answers that can be "off-topic"....
anything else is dealt with by voting. If you don't like an answer, or it does not add value to the site, or the OP, then down-vote it, otherwise, if it is great, provides good insights, then up-vote it.
If enough people downvote an answer it sort of disappears in to obscurity anyway.