成绩排序(Python实现) 摘要:解题思路:注意事项:参考代码:def sort_students(students): students.sort(key=lambda x: (x[2], x[0], x[1])) re…… 题解列表 2023年11月12日 0 点赞 0 评论 614 浏览 评分:0.0
成绩排序 (Python代码) 前提申明:我使用了两种解法但是结果都是错误50%,但没有找到问题所在,自己测试了几组特殊数据排序正确的分析:方法一:先按成绩冒泡排序,再按名字冒泡排序,再按年龄冒泡排序方法二:以成绩为排序要点,在该冒泡排序内,如果成绩相等,等判断名字,如果连名字都相等, 题解列表 2020年01月27日 0 点赞 2 评论 2526 浏览 评分:2.0
对矩阵二维数组还是不是很熟悉啊 摘要:解题思路:注意事项:折腾了这么久,不懈题解对不起自己看时间一道题也高了快一个小时了参考代码:##while True:## n=int(input())## lh=[]## for …… 题解列表 2022年05月27日 0 点赞 0 评论 590 浏览 评分:2.0
题目 1739: 成绩排序 摘要:解题思路:注意事项:参考代码:def compare_students(student): name, age, score = student return (score, name, …… 题解列表 2023年11月10日 0 点赞 0 评论 674 浏览 评分:2.0
成绩排序 (Python代码)最简方法sort(),无需思考 ```pythonwhileTrue:#测试数据有多组,因此要循环,否则就会答案错误50%students=[]N=int(input())whileN:tem=input().split()#分割输入字符name=tem[0]age=int(tem[1])score=int(tem[2])stude 题解列表 2020年02月15日 1 点赞 0 评论 1594 浏览 评分:7.6