possible bug?

the average of [4,5,5,5] should be 5.0 and not 4.5. It throws an error and says 4.5 should be the median

Replace this line with your code.


agree, the median of [4,5,5,5] is 5, but the median of [4,5,5,4] should be 4.5 (those lists are not the same)

the median is the middle value (or average of middle two lists) of a sorted list


okay. got it. I missed that it should be a sorted list. Thank you so much :slight_smile:


well, you sorted the list, but then never used it. Good you figured it out :slight_smile: