摘要: 一:get() //【例12-2】 用函数get和getline读取数据。 #include <iostream> using namespace std; int main() { char a,b,c,d; cin.get(a); cin.get(b); c = cin.get(); d = c 阅读全文
posted @ 2020-04-27 20:24 糖糖_彭 阅读(306) 评论(0) 推荐(0) 编辑
摘要: https://github.com/Light-City/CPlusPlusThings 阅读全文
posted @ 2020-04-27 10:54 糖糖_彭 阅读(375) 评论(0) 推荐(0) 编辑
摘要: /* 使用前向引用声明虽然可以解决一些问题,但它并不是万能的。需要注意的是, 尽管使用了前向引用声明,但是在提供一个完整的类声明之前,不能声明该类的对象, 也不能在内联成员函数中使用该类的对象。请看下面的程序段: */ //第一种 #include<iostream> class Fred; //前 阅读全文
posted @ 2020-04-27 10:52 糖糖_彭 阅读(617) 评论(0) 推荐(0) 编辑