摘要:
源程序: #include <iostream> using namespace std;class Point {public: Point(int x = 0, int y = 0) :x(x), y(y) { count++; } Point(Point&p) { x = p.x; y = p 阅读全文
posted @ 2020-02-06 21:09
bobo哥
阅读(205)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>#include <cmath>using namespace std; class Point{private: double x, y;public: Point() {}; Point(double a, double b) { x = a; y 阅读全文
posted @ 2020-02-06 20:48
bobo哥
阅读(179)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std;class Location{public: int x, y; void init(int initx,int inity); int Getx(); int Gety();};void Location::i 阅读全文
posted @ 2020-02-06 20:23
bobo哥
阅读(210)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std;class exa{ int a;public: exa(int b = 5) { a = b++; } void print() { a = a + 1; cout << a << " "; } void pr 阅读全文
posted @ 2020-02-06 20:16
bobo哥
阅读(134)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std; class CTest{private: int n;public: CTest() { n = 1; } int GetValue() const { return n; } int GetValue() { 阅读全文
posted @ 2020-02-06 20:12
bobo哥
阅读(147)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std; class base{private: int m;public: base() {}; base(int a) :m(a) {} int get() { return m; } void set(int a) 阅读全文
posted @ 2020-02-06 20:04
bobo哥
阅读(150)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std; class A{ int a, b;public: A(int x = 0, int y = 0) { a = x; b = y; }};int main(){ A *p; p = new A(4,5); sy 阅读全文
posted @ 2020-02-06 19:57
bobo哥
阅读(143)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std;class f{private: int x, y;public: void f1() { x = 10; y = 10; } void print() { cout << x << "," << y << en 阅读全文
posted @ 2020-02-06 19:52
bobo哥
阅读(142)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std; class Test{private: static int num;public: Test(int); void show();};int Test::num = 5;Test::Test(int n){ 阅读全文
posted @ 2020-02-06 19:48
bobo哥
阅读(159)
评论(0)
推荐(0)
摘要:
源程序: #include <iostream>using namespace std; class Aton{public: int X, Y; int zx, zy; void init(int i, int j) { zx = i; zy = j; } Aton(int i, int j, i 阅读全文
posted @ 2020-02-06 19:39
bobo哥
阅读(128)
评论(0)
推荐(0)

浙公网安备 33010602011771号