阅读程序4
来源:互联网 发布:王小波黑铁时代知乎 编辑:程序博客网 时间:2024/06/05 12:40
#include <iostream>using namespace std;class Pair{ int m; int n;public: Pair(int i,int j):m(i),n(j){} bool operator>(Pair p)const;};bool Pair::operator>(Pair p)const{ if(m!=p.m) return m>p.m; return n>p.n;}int main(){ Pair p1(3,4),p2(4,3),p3(4,5); cout<<(p1>p2)<<(p2>p1)<<(p2>p3)<<(p3>p2)<<endl; return 0;}
0 0
- noip2012 阅读程序4
- 阅读程序3、4
- 阅读程序4
- 补充阅读程序-4
- 阅读程序4
- 阅读程序4
- 阅读程序(4)
- 阅读程序4
- 阅读程序4
- 阅读程序(4)
- 阅读程序(4)
- 第四周程序阅读(4)
- 第四周阅读程序4
- 第四周 阅读程序 4
- 第五周程序阅读(4)
- 第六周程序阅读4
- 第六周程序阅读(4)
- 第六周 阅读程序 4
- 初学者之ORACLE生成执行计划
- 阅读程序3
- zabbix3.0.2 实现发送email报警的详细过程
- 07-图4 哈利·波特的考试
- 【学习小记】用splay维护序列
- 阅读程序4
- excel字符串拆分为行
- CentOS-6.5-x86_64 设置静态IP地址
- Glide优势与特点
- 注释驱动的 Spring cache 缓存介绍
- 浅谈设计模式之策略模式
- 实现复数类中的运算符重载2
- 第8课:Spark Streaming源码解读之RDD生成全生命周期彻底研究和思考
- [疯狂Java]基础类库:Random(随机数生成)、ThreadLocalRandom(线程安全随机数生成)