- 博客(3)
- 收藏
- 关注
原创 Python编程从入门到基础10-13
#10-13import jsondef get_sorted_username():‘’‘如果存储了用户名就获取他’’’filename = ‘usernumber.json’try:with open(filename) as f_obj:username = json.load(f_obj)except FileNotFoundError:return Noneelse:...
2019-07-08 10:39:55
251
原创 Python编程 从入门到实践 9-4
class Restaurant():def init(self,restaurant,cuisine_type):self.restaurant = restaurantself.cuisine_type = cuisine_typeself.number_served = 0def read_number(self): print(self.number_served) ...
2019-07-05 09:23:27
284
原创 Python编程 从入门到实践 习题8-11
打印列表def show_magicians(magicians):for magician in magicians:print(magician)修改列表def make_great(magicians):for i in range(3):magicians[i] = "the Great " + magicians[i]return magiciansmagicians ...
2019-07-03 12:57:48
313
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人