3 ms·
You even answered your own question. Your validation code is 293 characters and 8 lines, the example code is 95 characters and 6 lines and does more tests. An
by coldtea 8y ago
You even answered your own question.
Your validation code is 293 characters and 8 lines, the example code is 95 characters and 6 lines and does more tests.
And that's not even including your helpers which if one uses that lib, they wont have to write.
So, you wrote like 4 times the code, and made it even less flexible (eg. hardcoding the test for 100 in your isTestScore check).