问题 判断题

未上坡的车辆遇到这种情况让对向下坡车先行。

答案

参考答案:

单项选择题

Internet use appears to cause a decline in psychological well-being, according to re search at Carnegie Mellon University. Even people who spent just a few hours a week on the Internet (47) more depression and loneliness than those who logged on less frequently, the two-year study showed. And it wasn’’t that people who were already feeling (48) spent more time on the Internet, but that using the Net (49) appeared to cause the bad feelings. Researchers are puzzling over the results, which were completely (50) to their expectations. They expected that the Net would prove socially (51) than television, since the Net allows users to choose their information and to communicate with others. The fact that Internet use reduces time (52) for family and friends may account for the drop in well-being, researchers hypothesized. Faceless, bodiless "virtual" (53) may be less psychologically satisfying than actual conversation, and the relationships formed through it may be shallower. Another possibility is that (54) to the wider world via the Net makes users less satisfied with their lives. "But it’’s important to (55) this is not a bout the technology itself; it’’s about how it is used," says psychologist Christine Riley of Intel, one of the study’’s sponsors. "It really (56) to the need for considering social factors in terms of how you design applications and services for technology."WORD BANKA) communication I) badB) meaningful J) pointsC) exposureK) availableD) agrees L) repeatedlyE) efficiency M) rememberF) contraryN) experiencedG) connection O) healthierH) actually

填空题

阅读下列函数说明和C++代码,将应填入 (n) 处的字句写在对应栏内。

[说明]

在一些大型系统中,大多数的功能在初始化时要花费很多时间,如果在启动的时候,所有功能(包括不用的功能)都要全面初始化的话,会导致应用软件要花很多时间才能启动。因此常将程序设计成到了实际要使用某种功能的阶段才初始化该功能。

以下示例展示了Proxy(代理)模式,PrinterProxy类执行一些比较“轻”的方法,需要真正执行“重”的方法时才初始化Print类。图5-1显示了各个类间的关系。

[图5-1]

[*]

[C++代码]

class Printable

public:

virtual void setPrinterName(string name)=0;

virtual string getprinterName()=0;

virtual void print(string name)=0;

class Printer:public Printable

private:

string name;

public:

Printer(string name)

cout<<"正在产生Printer的对象实例"<<endl;

this->name=name;

void setPrinterName(string name)

this->name=name;

string getPrinterName()

return name;

void print(string msg)

cout<<"======="<<name<<"==========="<<endl;

cout<<msg<<endl;

class printerproxy :public (1)

private:

String name;

Printer *real;

public:

PrinterProxy(string name)

(2) =NULL;

this->name=name;

void setPrinterName(string name)

if( (3) )real->setPrinterName(name);

this->name=name;

string getPrinterName()

return name;

void print(string msg)

(4)

real->print(msg);

void realize()

if(real==NULL)real= (5)

(3)处填()。