Project Eule 第五题
来源:互联网 发布:单片机红外线控制开关 编辑:程序博客网 时间:2024/06/14 09:28
题目:2520是可以被1到10之间所有数都能整除得最小正整数,那么能被1--20之间所有数都整除的最小整数是多少
思路:找到能被2520和11--20之的数同时整除得最小数字从2520*11*13*17*19开始,以10为步长,开始轮训,找到最小的输出
代码
n=2520*11*13*17*19while n%2520!=0 or n%11!=0 or n%12!=0 or n%13!=0 or n%14!=0 or n%15!=0 or n%16!=0 or n%17!=0 or n%18!=0 or n%19!=0 or n%20!=0: n = n+10print (n)
- Project Eule 第五题
- project Euler第五题
- 【Project Euler】5 第五题
- hdu 2824 The Eule Function 筛式欧拉函数
- phing用户手册第五章Project Components译文
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- 第五题
- fatal: The remote end hung up unexpectedly error: failed to push some refs to ''
- EhCache使用详细介绍
- Web.XML 配置详解
- work_代码混淆引入保留前缀加密
- Mozilla internship
- Project Eule 第五题
- COCOS2D中对精灵的操作、对图片的各种操作
- 利用FPGA实现摄像机传感器接口
- 双摄像头测距的opencv实现
- 在solr的源码的基础上进行开发,把solr 4.4.0的源码导入到本地eclipse中,使用maven进行管理。
- Google app engine - Servlet Mapping for Google App Engine and Spring/404 no mapping found
- sizeof,终极无惑(上)
- 邮箱客户端设置
- Boost学习之CRC校验