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.
For clarity: if tests were to feed your solution an input with an
Eq
instance but not anOrd
instance, it would fail. So you are not implementing the specs fully; you are too restrictive.In short: no, but tests are inadequate, so yes.
To me it feels like rewriting the problem. Maybe the test spec should feed a list of a custom datatype with only
Eq
instance.is it ok to add an "Ord a" constraint?