问题 选择题

读我国某工业基地示意图,回答17~18题。

小题1:该工业基地是

A.京津唐工业基地

B.辽中南工业基地

C.珠江三角洲工业基地

D.沪宁杭工业基地小题2:该工业基地迎来了新的发展机遇,其主要得益于

A.交通便利

B.资源丰富

C.政策扶持

D.市场广阔

答案

小题1:B

小题2:C

小题1:本题考查我国四大工业基地的地理位置。根据图示该工业基地的发展条件是煤铁资源丰富,位于渤海北侧,属于辽中南工业基地。所以本题选择B选项。

小题2:本题考查工业区位因素。影响工业区位的因素有:土地、原料、动力、水源、交通运输、劳动力、市场和政府政策等。辽中南工业基地的复兴主要由于国家振兴东北老工业基地的政策影响。所以本题选择C选项。

计算题
填空题

使用VC++6.0打开考生文件夹下的源程序文件3.cpp,要求编写一个CMyShape类,含有求面积、周长等的纯虚函数,然后编写一个CRectangle类和CCircle类继承CMyShape,并实现求面积、周长的两个函数。在main函数中测试得到下面的结果:
在CMyShape类构函数造内
在CCircle类构造函数内
在CMyShape类构造函数内
在CRectangle类构造函数内
myCircle:Area=314.159 Girth=62.8319
myRectangle:Area=900 Girth=120
具体要求如下:
(1)定义求面积的纯虚函数,请在注释1后添加适当的语句。
(2)定义求周长的纯虚函数,请在注释2后添加适当的语句。
(3)请在注释3和注释4后添加适当的语句。
注意:除在指定位置添加语句之外,不要改动程序中的其他内容。
试题程序:
#include<iostream.h>
#include<math.h>
#define PI 3.1415926
class CMyPoint

public:
int x,y;
CMyPoint(int tx,int ty):x(tx),y(ty)

class CMyShape

public:
CMyShape()cout<<"在CMyShape类构造函数内"<<end1;
//********1********
//********2********
protected:

class CCircle:public CMyShape

public:
CCircle(CMyPoint i,double j):CMyShape(),arcCenter(i),radius(j)

cout<<"在CCircle类构造函数内"<<end1;

double GetArea()

return PI *radius *radius;

double GetGirth()

return 2*PI*radius;

private:
CMyPoint arcCenter;
double radius;

class CRectangle:public CMyShape

public:
CRectangle(CMyPoint lt,CMyPoint rb):leftTop(lt),rightBottom(rb),CMyShape()

cout<<"在CRectangle类构造函数内"<<end1;

double GetArea()

int width=abs(rightBottom.x-leftTop.x);
int height=abs(rightBottom.y-leftTop.y);
return width *height;

double GetGirth()

int width=abs(rightBottom.x-leftTop.x);
int height=abs(rightBottom.y-leftTop.y);
return 2*(width+height);

private:
CMyPoint leftTop,rightBottom;

void main()

CMyShape *myShape=NULL;
CCircle *myCircle=new CCircle(CMyPoint(5,5),10);
CRectangle *myRectangle=new CRectangle(CMyPoint(0,0),CMyPoint(30,30));
//********3********
cout<<"myCircle:"<<"Area="<<myShape—>GetArea()<<"\t"<<"Girth="<<myShape—>GetGirth()<<end1;
//********4********
cout<<"myRectangle:"<<"Area="<<myShape—>GetArea()<<"\t"<<"Girth="<<myShape—>GetGirth()<<end1;