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.
No, I mean you are using the
max
andmin
functions on a list of strings. The way you sort a list of strings is different form how you sort a list of numbers.See: https://www.codewars.com/kata/554b4ac871d6813a03000035/discuss#60cb692f9c75d0003d7b9a79
Which programming language is this?
The issue is definitely your code, and my first guess is that you are sorting a list of strings, instead of a list of numbers.
Other than that, you are doing things in a loop for some reason, so you are finding the highest and lowest values multiple times.