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.
Nice kata to practice your regex skills, thanks.
Decimals are only 2 digits.
Needs random tests
1'234 CHF
This is ambiguious. There is only 1 symbol, how do we know whether it's a thousand separator or it's a decimal mark?
There seems to be a minor issue with the decimalmark testcase for France.
According to the test output an "," is the expected decimal mark but the currency string does not
contain this character.
Random tests with numbers > 1000 sometimes expect the wrong format:
1234 expect '1234' but the correct solution would be '1.234'
Also: a valid currency-string should always have 2 decimals, so the above should actually be
1234 -> '1.234,00'
The supplied testcases truncate the decimals if they end with a 0:
'.10' becomes '.1' and '.00' gets removed alltogether