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

📄 rectangle.h

📁 计算并输出下述各种算法在不同内存容量下的命中率大整数大整数大整数
💻 H
字号:
#include <iostream>
using namespace std;

class Rectangle : public Shape
{
public:
	Rectangle(double _width, double _height);
	double area();
	double girth();
	void show();
private:
	Rectangle();
	double width;
	double height;
};

Rectangle::Rectangle(double _width, double _height)
{
	width = _width;
	height = _height;
}

double Rectangle::area()
{
	return width * height;
}

double Rectangle::girth()
{
	return (width + height) * 2;
}

void Rectangle::show()
{
	Shape::show();
	cout<<"Type: Rectangle"<<endl;
}

⌨️ 快捷键说明

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