摘要: #include <iostream>#include <cmath>using namespace std; class calc //类名:calc(计算器){private: int a,b; int p,m;public: calc(){} //不带参数的构造函数 void input(); 阅读全文
posted @ 2019-06-30 20:21 bobo哥 阅读(5680) 评论(0) 推荐(0)
摘要: #include <stdio.h>#include <stdlib.h>#include <iostream> using namespace std;const int MaxSize=8; typedef struct{ int stuno; char stuname[20]; int stu 阅读全文
posted @ 2019-06-30 19:18 bobo哥 阅读(2180) 评论(0) 推荐(0)
摘要: #include <iostream>#include <stdlib.h>using namespace std;const double PI=3.14159; //基类的定义class Point{private: int x,y;public: Point(int xx,int yy) { 阅读全文
posted @ 2019-06-30 16:52 bobo哥 阅读(827) 评论(0) 推荐(0)
摘要: //求立方体的体积、表面积(c++) #include <iostream>#include <stdlib.h>#define COST 20using namespace std; class tiji{private: double length,width,height;public: ti 阅读全文
posted @ 2019-06-30 16:46 bobo哥 阅读(2698) 评论(0) 推荐(0)
摘要: /* Name : prime.c Author : zhangsan Version : Copyright : Your copyright notice Description : 键盘输入一个整数,判断是否是素数 */ #include <stdio.h> #include <stdlib. 阅读全文
posted @ 2019-06-30 07:27 bobo哥 阅读(4177) 评论(0) 推荐(0)
摘要: /* Name : p146.c Author : zhangsan Version : Copyright : Your copyright notice Description : 1+2+3+4+...+10, 教材p146 */ #include <stdio.h> #include <st 阅读全文
posted @ 2019-06-30 07:23 bobo哥 阅读(1514) 评论(0) 推荐(0)
摘要: /* Name : p144.c Author : zhangsan Version : Copyright : Your copyright notice Description : 1,2,3,4,5这五个数中作取3个组成互不相等的数,并算出有多少个 */ #include <stdio.h># 阅读全文
posted @ 2019-06-30 07:21 bobo哥 阅读(194) 评论(0) 推荐(0)
摘要: /* Name : test.c Author : asdfasdf Version : Copyright : Your copyright notice Description : 两个数比较,找出较大者,教材p143 */ #include <stdio.h>#include <stdlib. 阅读全文
posted @ 2019-06-30 07:18 bobo哥 阅读(366) 评论(0) 推荐(0)
摘要: /* Name : max4.c Author : zhangsan Version : Copyright : Your copyright notice Description : 四个数求最大值 */ #include <stdio.h>#include <stdlib.h>int max2( 阅读全文
posted @ 2019-06-30 07:16 bobo哥 阅读(1277) 评论(0) 推荐(0)
摘要: 源程序如下: // // main.cpp // yiyuanercifangcheng // Created by duanqibo on 2019/6/29. // Copyright © 2019年 duanqibo. All rights reserved. // 本题是一个实现一元二次方程 阅读全文
posted @ 2019-06-29 18:25 bobo哥 阅读(263) 评论(0) 推荐(0)