leimobandingyi.cpp

来自「对c++中一些摸板及派生应用的举例」· C++ 代码 · 共 16 行

CPP
16
字号
#include <iostream>
using namespace std;
template<class numtype>
class Compare
 {public:
   Compare(numtype a,numtype b)
    {x=a;y=b;}
   numtype max()
    {return (x>y)?x:y;}
   numtype min()
    {return (x<y)?x:y;}
  private:
    numtype x,y;
 };

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?