Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
You can validate source code.
isMathySolution(require('fs').readFileSync('/home/codewarrior/solution.txt', 'utf8'));
:)This isn't affected by people using string manipulations, right?
I asked why you'd want to encourage people to do it 'math-y' because I don't think it adds much difficulty or improve performance. Isn't it just some
log10
,pow
,floor
?I'd recommend authoring a new kata "find the most significant digit without string manipulation" if it doesn't exist yet and require solving arithmetically.
Can you tell me why you want to encourage people to find the most significant digit arithmetically when the goal is to "provide a function that returns the distribution of the most significant digits"?