更新时间:2023-02-06 13:57:54
您的示例对我有用.我建议您不要使用list
作为变量名,因为它是内置类型.
Your example works for me. I would advise you not to use list
as a variable name, since it is a builtin type.
您也可以尝试执行以下操作:
You could try doing something like this also:
list.sort(key=lambda item: (item['points'], item['time']))