在思考的六边形战士很想去旅行
在思考的六边形战士很想去旅行
全部文章
分类
归档
标签
去牛客网
登录
/
注册
在思考的六边形战士很想去旅行的博客
全部文章
(共90篇)
题解 | 查字典
word_list = { "a": ["apple", "abandon", "ant"], "b": ["banana", "bee", &...
2025-09-23
0
15
题解 | 生成字典
# zip(list1,list2)方法,返回迭代器iterator,迭代器由(list1_key1,list2_value1)元组构成; # 要获取其具体内容,须先转换成字典或列表等 name_list = input().split() language_list = input().split...
2025-09-23
1
15
题解 | 喜欢的颜色
result_dict = { "Allen": ["red", "blue", "yellow"], "Tom": ["green", "white&q...
2025-09-23
1
20
题解 | 首都
cities_dict = { "Beijing": {"Capital": "China"}, "Moscow": {"Capital": "Russia"}, ...
2025-09-23
1
20
题解 | 姓名与学号
my_dict_1 = {"name": "Niuniu", "Student ID": 1} my_dict_2 = {"name": "Niumei", "Student ID"...
2025-09-23
1
14
题解 | 毕业生就业调查
# dict.keys()返回字典键视图对象(可迭代,类似于集合;具有动态性,视图对象会实时反映原字典的变化), # dict.values(),dict.items()同理 survey_list = ["Niumei", "Niu Ke Le", &quo...
2025-09-23
1
16
题解 | 遍历字典
# dict[key1] == value1 # sorted(iterable,reverse:bool=False)方法,默认按升序给可迭代对象排序,返回列表; # 如果可迭代对象是字典,对字典的键排序,返回的列表里也只含字典的键 operator_dict = {"<"...
2025-09-23
1
12
题解 | 修改报名名单
entry_form = ('Niuniu','Niumei') print(entry_form) try: entry_form[1] = 'Niukele' except TypeError: print('The entry form cannot be modified!'...
2025-09-23
1
15
题解 | 牛牛的矩阵相加
matrix_list = [[1, 2, 3], [4, 5, 6], [7, 8, 9]] number = int(input()) for i in range(0, len(matrix_list)): for j in range(0, len(matrix_list[i])):...
2025-09-23
1
14
题解 | 牛牛的矩阵相加
matrix_list = [[1, 2, 3], [4, 5, 6], [7, 8, 9]] number = int(input()) for i in range(0,len(matrix_list)): for j in range(0,len(matrix_list[i])): ...
2025-09-23
1
11
首页
上一页
1
2
3
4
5
6
7
8
9
下一页
末页