?? 7_2.cpp
字號:
//7_2.cpp
#include<iostream>
#include<cmath>
#include "rectangle.h"
using namespace std;
void main()
{
Rectangle rect; //聲明Rectangle類的對象
rect.InitR(2,3,20,10); //設(shè)置矩形的數(shù)據(jù)
rect.Move(3,2); //移動矩形位置
cout<<"The data of rect(X,Y,W,H):"<<endl;
cout<<rect.GetX()<<"," //輸出矩形的特征參數(shù)
<<rect.GetY()<<","
<<rect.GetW()<<","
<<rect.GetH()<<endl;
}
//End of 7_2.cpp
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -