<分区>
以下代码尝试按升序对字典的键进行排序。由于某种原因,“6:58”和“7:56”没有正确排序,但其他的排序正确。这可能是什么原因造成的?
print(dictionary.keys)
sortedKeys = dictionary.keys.sorted(by: <)
print(sortedKeys)
["7:56", "14:57", "11:57", "6:58", "10:59", "17:59"]
["10:59", "11:57", "14:57", "17:59", "6:58", "7:56"]