#include
#include
#include
using namespace std;
class Rectangle
{
public:
Rectangle( int l, int t, int r, int b )
{
left = l, top = t, right = r, bottom = b;
}
float Diagonal()
{
return sqrt( (right-left)*(right-left) + (bottom-top)*(bottom-top) );
}
void Show()
{
cout<
protected:
int left, top, right, bottom;
};
void main()
{
Rectangle *r1;
r1 = new Rectangle( 10, 10, 20, 20 );
r1->Show();
delete r1;
}