operator.h

来自「这是c++编程方面的名著的例子代码」· C头文件 代码 · 共 30 行

H
30
字号
#ifndef _operator__h
#define _operator__h
class operator_type{
protected:
    int Priority;
    char Operator;
    char Function[10];
public:
     operator_type(void);
     operator_type(char N);
     operator_type(const operator_type &N);
     operator_type &operator=(const operator_type &N);
     int operator>(const operator_type &N) const;
     int operator<(const operator_type &N) const;
     int operator==(const operator_type &N) const;
     int operator<=(const operator_type &N) const;
     int operator>=(const operator_type &N) const;
     char op(void);
     void op(char N);
     int priority(void);
     void priority(int Rank);
     char *function(void);
     void function(char *X);
     double function(double);

};

#endif

⌨️ 快捷键说明

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