10 2022 档案

摘要:#pragma warning(disable:4996) #define _CRT_SECURE_NO_WARNINGS 1 const float c = 3e11; #include <iostream> using namespace std; class Antenna { public: 阅读全文
posted @ 2022-10-30 14:38 CodeMagicianT 阅读(85) 评论(0) 推荐(0) 编辑
摘要:天线知识点 1.天线实现宽带方法 多谐振天线可以实现宽阻抗宽带。 A.难点:如何产生或控制多个谐振点。 常用的方法: 多模辐射单元、多天线单元、电抗或寄生单元加载、阻抗变换网络 常用的多谐振天线有:套筒天线,枝节加载振子、谐振加载振子、多边形振子、耦合馈电振子等 2.缝隙天线设计追求的目标 小型化、 阅读全文
posted @ 2022-10-28 13:29 CodeMagicianT 阅读(783) 评论(0) 推荐(0) 编辑
摘要:1.动态联编和静态联编(重点难点) 1.静态联编 编译器会根据函数调用的对象类型,在编译阶段就确定函数的调用地址,这就是静态联编(早绑定) 2.虚函数 在普通成员函数前面加virtual,该函数变为虚函数,是告诉编译器这个函数要晚绑定 3.动态联编 在运行阶段才确定调用哪个函数(晚绑定), 4.动态 阅读全文
posted @ 2022-10-17 22:00 CodeMagicianT 阅读(62) 评论(0) 推荐(0) 编辑
摘要:1.多继承概念 我们可以从一个类继承,我们也可以能同时从多个类继承,这就是多继承。但是由于多继承是非常受争议的,从多个类继承可能会导致函数、变量等同名导致较多的歧义。 class Base1{ public: void func1(){ cout << "Base1::func1" << endl; 阅读全文
posted @ 2022-10-16 21:32 CodeMagicianT 阅读(48) 评论(0) 推荐(0) 编辑
摘要:1.继承中的对象模型 在C++编译器的内部可以理解为结构体,子类是由父类成员叠加子类新成员而成: class Aclass{ public: int mA; int mB; }; class Bclass : public Aclass{ public: int mC; }; class Cclas 阅读全文
posted @ 2022-10-16 21:31 CodeMagicianT 阅读(48) 评论(0) 推荐(0) 编辑
摘要:1 运算符重载 1.1 运算符重载只针对自定义数据类型 1.2 基础数据类型的运算符不要去修改,不要去重载 1.3 运算符重载不要改变运算符本身的寓意 1.4 使用运算符重载是为了让代码更加易读,更加清晰 1.5 一般有全局函数,成员函数 1.6 运算符重载本质上是函数调用 1.7 类里编译器给我们 阅读全文
posted @ 2022-10-15 21:52 CodeMagicianT 阅读(20) 评论(0) 推荐(0) 编辑
摘要:01.数组类(了解) 1.目的:设计一个类,该类有数组的功能,可以存储数据,可以删除修改数据 2.设计核心数据 1.属性:指针(指向堆区空间),数组实际存储的元素个数,数组容量 2.方法:构造(开辟堆区空间),尾插,头插,指定位置插入,尾删,头删,获取指定位置的值,指定位置修改值,获取数组元素个数, 阅读全文
posted @ 2022-10-15 21:51 CodeMagicianT 阅读(28) 评论(0) 推荐(0) 编辑
摘要:程序: #pragma warning(disable:4996) #define _CRT_SECURE_NO_WARNINGS 1 //2022年10月15日20:24:40 #include <iostream> using namespace std; class Father { publ 阅读全文
posted @ 2022-10-15 21:05 CodeMagicianT 阅读(30) 评论(0) 推荐(0) 编辑
摘要:1.为什么要有继承 //网页类 class IndexPage{ public: //网页头部 void Header(){ cout << "网页头部!" << endl; } //网页左侧菜单 void LeftNavigation(){ cout << "左侧导航菜单!" << endl; } 阅读全文
posted @ 2022-10-15 20:09 CodeMagicianT 阅读(39) 评论(0) 推荐(0) 编辑
摘要:字符串类.cpp #pragma warning(disable:4996) #define _CRT_SECURE_NO_WARNINGS 1 //2022年10月14日21:22:09 #include<iostream> using namespace std; #include "MyStr 阅读全文
posted @ 2022-10-15 18:56 CodeMagicianT 阅读(23) 评论(0) 推荐(0) 编辑
摘要:程序1: #pragma warning(disable:4996) #include <iostream> using namespace std; class Maker { public: Maker() { a = 0; } void SetA(int val) { a = val; } / 阅读全文
posted @ 2022-10-15 18:56 CodeMagicianT 阅读(20) 评论(0) 推荐(0) 编辑
摘要:1.类里有重载函数调用符号的类实例化的对象也叫仿函数 2.仿函数的作用:1.方便代码维护 2.方便有权限的调用函数。3.作为算法的策略 程序1: #pragma warning(disable:4996) #include <iostream> using namespace std; class 阅读全文
posted @ 2022-10-14 20:13 CodeMagicianT 阅读(20) 评论(0) 推荐(0) 编辑
摘要:1.智能指针类是管理另一个类的对象的释放 class Maker { public: Maker() { cout << "无参构造" << endl; } void printMaker() { cout << "hello Maker" << endl; } ~Maker() { cout << 阅读全文
posted @ 2022-10-14 18:50 CodeMagicianT 阅读(26) 评论(0) 推荐(0) 编辑
摘要:程序1: 11数组下标重载.cpp #pragma warning(disable:4996) #include <iostream> using namespace std; #include "MyArray.h" void test() { MyArray arr; for( int i = 阅读全文
posted @ 2022-10-13 20:40 CodeMagicianT 阅读(22) 评论(0) 推荐(0) 编辑
摘要:有的时候在VS中遇到的error C1083: 无法打开**: “ * .*”: No such file or directory的错误,这里总结了我遇到过的情况: 错误 C1083 无法打开包括文件: “MyArray.h”: No such file or directory 1.第一种情况: 阅读全文
posted @ 2022-10-13 19:58 CodeMagicianT 阅读(692) 评论(0) 推荐(0) 编辑
摘要:1.前置和后置(++/--)运算符重载 重载的++和--运算符有点让人不知所措,因为我们总是希望能根据它们出现在所作用对象的前面还是后面来调用不同的函数。解决办法很简单,例如当编译器看到++a(前置++),它就调用operator++(a),当编译器看到a++(后置++),它就会去调用operato 阅读全文
posted @ 2022-10-13 14:32 CodeMagicianT 阅读(42) 评论(0) 推荐(0) 编辑
摘要:程序1: #pragma warning(disable:4996) //2022年10月12日21:26:43 #include <iostream> using namespace std; class Maker { public: Maker() { id = 0; age = 0; } M 阅读全文
posted @ 2022-10-12 21:38 CodeMagicianT 阅读(19) 评论(0) 推荐(0) 编辑
摘要:1.赋值(=)运算符重载 赋值符常常初学者的混淆。这是毫无疑问的,因为’=’在编程中是最基本的运算符,可以进行赋值操作,也能引起拷贝构造函数的调用。 class Person{ friend ostream& operator<<(ostream& os,const Person& person){ 阅读全文
posted @ 2022-10-12 21:04 CodeMagicianT 阅读(48) 评论(0) 推荐(0) 编辑
摘要:1.视频内容 程序1: #pragma warning(disable:4996) #include <iostream> using namespace std; void test() { int a; cin >> a; cout << a << endl; } class Maker { f 阅读全文
posted @ 2022-10-05 22:23 CodeMagicianT 阅读(33) 评论(0) 推荐(0) 编辑
摘要:1.视频内容 程序1: #pragma warning(disable:4996) //2022年10月5日21:11:12 #include <iostream> using namespace std; class Maker { public: Maker(int id, string nam 阅读全文
posted @ 2022-10-05 22:22 CodeMagicianT 阅读(45) 评论(0) 推荐(0) 编辑
摘要:1.前置和后置(++/--)运算符重载 重载的++和--运算符有点让人不知所措,因为我们总是希望能根据它们出现在所作用对象的前面还是后面来调用不同的函数。解决办法很简单,例如当编译器看到++a(前置++),它就调用operator++(a),当编译器看到a++(后置++),它就会去调用operato 阅读全文
posted @ 2022-10-05 21:09 CodeMagicianT 阅读(61) 评论(0) 推荐(0) 编辑
摘要:1 运算符重载 1.1 运算符重载基本概念 运算符重载,就是对已有的运算符重新进行定义,赋予其另一种功能,以适应不同的数据类型。(运算符重载不能改变本来寓意,不能改变基础类型寓意) 运算符重载(operator overloading)只是一种”语法上的方便”,也就是它只是另一种函数调用的方式。 在 阅读全文
posted @ 2022-10-03 21:50 CodeMagicianT 阅读(148) 评论(0) 推荐(0) 编辑
摘要:程序1: 01数组类.cpp: #pragma warning(disable:4996) //2022年10月2日20:33:53 #include <iostream> using namespace std; #include "MyArray.h" void printMyArray(MyA 阅读全文
posted @ 2022-10-03 18:58 CodeMagicianT 阅读(21) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示