当前位置: 首页 > news >正文

建设职业技术学院网站做赚钱的网站有哪些

建设职业技术学院网站,做赚钱的网站有哪些,it培训课程,做外文翻译的网站复数类的实现#xff0c;写出三种构造函数#xff0c;算术运算符、关系运算符、逻辑运算符重载尝试实现自增、自减运算符的重载 #include iostream using namespace std; class Num {int rel; //实部int vir; //虚部 public:Num():rel(2),vir(1){}Num(int rel,…复数类的实现写出三种构造函数算术运算符、关系运算符、逻辑运算符重载尝试实现自增、自减运算符的重载  #include iostream using namespace std; class Num {int rel; //实部int vir; //虚部 public:Num():rel(2),vir(1){}Num(int rel,int vir):rel(rel),vir(vir){}Num operator(const Num other){cout Num的拷贝赋值函数 endl;this-rel other.rel;this-vir other.vir;return *this;}friend Num operator(const Num n1,const Num n2);Num operator-(Num other);friend Num operator*(const Num n1,const Num n2);Num operator/(const Num n1);friend Num operator%(const Num n1,const Num n2);friend bool operator(const Num n1,const Num n2);bool operator(const Num n1);friend bool operator(const Num n1,const Num n2);bool operator(const Num n1);friend bool operator(const Num n1,const Num n2);friend bool operator(const Num n1,const Num n2);bool operator||(const Num n1);friend Num operator(Num n1);Num operator(int);friend Num operator--(Num n1);Num operator--(int);void show(); }; Num operator(const Num n1,const Num n2) {Num temp;temp.rel n1.reln2.rel;temp.vir n1.virn2.vir;return temp; } Num Num::operator-(Num other) {Num temp;temp.rel this-rel-other.rel;temp.vir this-vir-other.vir;return temp; } Num operator*(const Num n1,const Num n2) {Num temp;temp.rel n1.rel*n2.rel;temp.vir n1.vir*n2.vir;return temp; } Num Num::operator/(const Num n1) {Num temp;temp.rel this-rel/n1.rel;temp.vir this-vir/n1.vir;return temp; } Num operator%(const Num n1,const Num n2) {Num temp;temp.rel n1.rel%n2.rel;temp.vir n1.vir%n2.vir;return temp; } bool operator(const Num n1,const Num n2) {if(n1.reln2.rel){return n1.reln2.rel;}else if(n1.reln2.rel){return n1.virn2.vir;}return n1.reln2.rel; } bool Num::operator(const Num n1) {if(this-reln1.rel){return this-reln1.rel;}else if(this-reln1.rel){return this-virn1.vir;}return this-reln1.rel; } bool operator(const Num n1,const Num n2) {if(n1.reln2.rel){return n1.reln2.rel;}else if(n1.reln2.rel){return n1.virn2.vir;}return n1.virn2.vir; } bool Num::operator(const Num n1) {if(this-reln1.rel){return this-reln1.rel;}else if(this-reln1.rel){return this-virn1.vir;}return this-reln1.rel; } bool operator(const Num n1,const Num n2) {if(n1.reln2.rel){return n1.reln2.rel;}else if(n1.reln2.rel){return n1.virn2.vir;}return n1.virn2.vir; }bool operator(const Num n1,const Num n2) {return (n1.reln2.rel)||(n1.virn2.vir); } bool Num::operator||(const Num n1) {return (this-rel||n1.rel)(this-vir||n1.vir); } Num operator(Num n1) {(n1.rel);(n1.vir);return n1; } Num Num::operator(int) {Num temp;temp.relthis-rel;temp.virthis-vir;return temp; } Num operator--(Num n1) {--(n1.rel);--(n1.vir);return n1; } Num Num::operator--(int) {Num temp;temp.relthis-rel--;temp.virthis-vir--;return temp; } void Num::show() {cout rel vir i endl; } int main() {Num n1;Num n2(1,4);Num n3;n3 n1n2;n3.show();Num n4;n4n1-n2;n4.show();n4;n4.show();--n4;n4.show();cout(n4n3)endl;Num n5;n5--;n5.show();n5;n5.show();cout(n2n3)endl;cout(n2||n5)endl;return 0; }
http://www.zqtcl.cn/news/21181/

相关文章:

  • 网站地图咋做wordpress 私信插件
  • 网站模板开发主要作用建立网站对吗
  • 营销网站文章去那找信阳网络推广公司
  • 做房产网站需要注意什么怎样自己制作app软件卖货
  • 广告设计网站都有哪些wordpress微信按钮弹框
  • 唐山百度搜索排名优化网站建设公司推荐乐云seo
  • 软件园专业做网站网站的标签修改
  • 做网站的公司有多少家网站新开怎么做营销
  • 白种女人做爰网站权威的建筑工程网站
  • 上海网站建设价格网页版梦幻西游辅助工具
  • 网站的优化承诺郑州网站设计收费
  • 网站建设中 优秀账户的标准做自动发货网站
  • 免费做网站百度能录入网站统计工具是什么意思
  • 北京市通信管理局 网站备案wordpress4.4.1下载
  • 黄岛做网站找哪家好企业做网站的注意什么问题
  • 在什么地方可以接到做网站的活海口网站建设公司排名
  • 工业设计网站哪个最揭阳网页制作
  • 长沙协会网站设计专业服务建立一个自己的网页
  • 滨江区高端网站建设首码项目网
  • php 网站响应时间wordpress 改为中文字体
  • 太原网站推广排名怎么学做电商然后自己创业
  • 江苏中南建设集团网站是多少钱微信公众号小程序是什么
  • 做外贸做几个网站合适怎样做软件网站
  • 合作在惠州做网站wordpress是国外服务器吗
  • 网站两侧对联广告图片建设工程合同无效工程价款的结算
  • 旅行社网站建设网页论坛
  • pathon做网站网站的内容
  • 网站访问速度跟服务器cpu和内存和带宽哪个重要做网站猫要做端口映射吗
  • 广州做网站专业公司怎么做网站缩略图
  • 网站权重查询接口爱企业查询