自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(4)
  • 收藏
  • 关注

原创 2020-09-27

例题4,8个教师随机入住3个房间 import random offices = [[], [], []] names = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h'] for name in names: index = random.randint(0, 2) offices[index].append(name) for i, office in enumerate(offices): print('办公室%d有%d人。' % (i, l

2020-09-27 16:46:38 55

原创 2020-09-27

例题3购物车小程序 products = [['iphone', 6888], ['MacPro', 14800], ['小米8', 2499], ['Coffee', 31], ['book', 60], ['Nike', 699]] print('-' * 6 + ' 商品列表 ' + '-' * 6) for i, element in enumerate(products): print(i, '\t', element[0], '\t', element[1]) shoping_car

2020-09-27 15:53:22 90

原创 2020-09-27

九九乘法表 for i in range(1, 10): for j in range(1, i + 1): print('%d*%d = %d' % (j, i, i * j), end=' ') print('\n')

2020-09-27 15:29:09 49

原创 例题1猜拳小游戏

学习目标: python爬虫基础 学习内容: 例题1猜拳小游戏 学习产出: # -- codeing = utf-8 -- @Time : 2020/9/25 16:58 @Author : lmfors @File : fingerguessing.py @software: PyCharm import random while 1: computer_number = random.randint(0, 2) user_number = int(input(‘please input 0(石头)

2020-09-27 09:38:50 133

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除