- 博客(3)
- 收藏
- 关注
原创 中秋节分月饼-python实现
题目描述: 中秋节,公司分月饼,m个员工,买了n个月饼,m<=n,每个员工至少分1个月饼,但可以分多个,单人份到最多月饼的个数为Max1,单人分到第二多月饼的个数是Max2,Max1-Max2<=3,。同理,单人分到第n-1多月饼的个数是Max(n-1),单人分到第n多月饼的个数是Max(n),Max(n-1)-Max(n)<=3。请问有多少种分月饼的方法? 题解(python): def distribute(m,p,k): if p<=0: return
2022-01-07 23:58:46
1603
原创 使用celery和redis测试小程序时的一个坑
使用celery和redis测试小程序时的一个坑 报错信息如下: 如图,最后显示了一个结果: value is not an integer or out of range 错误修正: 查看错误信息里有一条: File “c:\users\sunfang\desktop\ven\lib\site-packages\celery\backends\redis.py”, line 161, in s...
2019-12-03 12:35:48
372
原创 Django学习中遇到的问题(1)django migration No migrations to apply
(ven) PS C:\Users…\Desktop\pytest\test5> python manage.py makemigrations Migrations for ‘booktest’: 0001_initial.py: - Create model AreaInfo - Create model PicTest (ven) PS C:\Users…\Desktop\pytest...
2019-11-27 15:41:16
419
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人