题解 | #牛牛的反转列表#
牛牛的反转列表
https://www.nowcoder.com/practice/e641566c6a5d4020aa7a2f9e41ff125f
num = [3, 5, 9, 0, 1, 9, 0, 3] num_r = [] # print(num) for i in reversed(num): num_r.append(i) print(num_r)
确实,题目的要求的输出有问题。只输出反转后的列表就可ac
牛牛的反转列表
https://www.nowcoder.com/practice/e641566c6a5d4020aa7a2f9e41ff125f
num = [3, 5, 9, 0, 1, 9, 0, 3] num_r = [] # print(num) for i in reversed(num): num_r.append(i) print(num_r)
确实,题目的要求的输出有问题。只输出反转后的列表就可ac
相关推荐