⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 employee.h

📁 数据结构课程第一次实验 要求:1.基类和派生类的定义和实现(.h .cpp) 2.+ 运算符重载 3.<< 运算符重载 4.构造与重载函数应用
💻 H
字号:
#ifndef EMPLOYEE_H
#define EMPLOYEE_H

#include <iostream>
#include <string>

using namespace std;

class Employee
{
public:
	string name;
	int salary;

	Employee(){};
	Employee(string,int);                                      
	friend Employee operator+(Employee&, Employee&);           //重载运算符+
	friend ostream& operator<<(ostream&, Employee&);           //重载流插入运算符<<
};

#endif

⌨️ 快捷键说明

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