习题6.3
来源:互联网 发布:windows rt连接口 编辑:程序博客网 时间:2024/06/14 08:07
这里写代码片#include <stdio.h>int main(){ int x; int find=0; /* 标志变量初值置为假 */ do{ x++; find=(x%2==1 && x%3 ==2 && x%5==4 &&x%6 ==5 && x%7 ==0);}while (!find) ; printf("x=%d\n" ,x);}
运行结果:
知识点:
1.学会do-while语句的使用;
2.使用穷举法编程。
心得体会:
1.先定义变量再赋值,注意“=”和“==”的使用;
2.学会使用穷举法。
阅读全文
0 0
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- 习题6.3
- apue 习题6.3
- 习题6 6.3
- 习题6(6.3)
- 习题6.3程序改错
- 习题
- 习题
- 习题
- 习题
- windows系统启用2个以上的mysql服务
- title标签,head部分
- 《From Zero to Hero – 从1000个代码案例中学习人工智能和大数据》课程
- 机器学习学习笔记--反向传播神经网络
- 控制语句
- 习题6.3
- [python] LDA处理文档主题分布及分词、词频、tfidf计算
- Luogu 3805(manacher)
- 机器人sci
- java学习之路
- MYSQL 中 LIMIT 用法
- python函数——编码问题——str与Unicode的区别
- 通过考试
- 最近公共祖先(LCA) RMQ解决