更多“Look ! The traffic light is red.I ( ) stop my car. ”相关问题
  • 第1题:

    An engineer is reviewing another engineer‘s sample configuration for a GRE tunnel used to pass IPv6 traffiC. The tunnel ha s not yet been configured on the router.Which of the following commands is not required for the configuration to pass IPv6 traffic?()

    A. tunnel source

    B. tunnel destination

    C. tunnel mode

    D. All these commands are requireD


    参考答案:C

  • 第2题:

    OSPF is a link-state routing protocol。It is designed to be run internal to a single ()system。Each OSPF router maintains an identical ()describing the autonomous system’s topology。From this database,a routing table is calculated by constructing a shortest-path ()。OSPF recalculates routes quickly in the face of topological changes,utilizing a minimum of routing () traffic。OSPF provides support for equal-cost multipath。An area routing capability is provided,enabling an additional level of routing protection and a reduction in routing protocol (75)。

    A.flow
    B.state
    C.traffiC.
    D.stream

    答案:C
    解析:
    OSPF是一种链路状态路由协议。该协议被设计成运行在单一的自治系统内部。每一个OFPF路由器都保持了同样的数据库,该数据库可以描述自治系统的拓扑图。通过该数据库,可以搭建的最短路径树以此计算路由表。OSPF在拓扑发生变化时,利用最小路由组播流量的快速重新计算路由。OSPF支持多条等价路径。OSPF提供区域路由的能力,在路由协议流量中赋予一个额外的路由保护和路由剪截能力。

  • 第3题:

    MySQL使用()文件中的配置参数。

    A.my-larger.ini

    B.my-small.ini

    C.my-huge.ini

    D.my.ini


    my.ini

  • 第4题:

    阅读下列说明和C++代码,回答问题,将解答填入答题纸的对应栏内。
    【说明】
    某灯具厂商欲生产一个灯具遥控器,该遥控器具有7个可编程的插槽,每个插槽都有开关按钮,对应着一个不同的灯。利用该遥控器能够统一控制房间中该厂商所有品牌灯具的开关,现采用Command(命令)模式实现该遥控器的软件部分。Command模式的类图如下图所示。

    【C++代码】

    class Light {public: Light(stringname) { /* 代码省略 */ } void on() {/* 代码省略 */ } // 开灯 void off() {/* 代码省略 */ } // 关灯};class Command {public: (1) ;};class LightOnCommand:public Command { // 开灯命令private: Light* light;public: LightOnCommand(Light* light) { this->light=light; } voidexecute() { (2) ; }};class LightOffCommand:public Command { // 关灯命令private: Light *light;public: LightOffCommand(Light* light) { this->light=light; } voidexecute() { (3) ; }};class RemoteControl{ // 遥控器private: Command*onCommands[7]; Command*offCommands[7];public: RemoteControl() { /* 代码省略*/ } voidsetCommand(int slot, Command* onCommand, Command* offCommand) { (4) =onCommand; (5) =offCommand; } voidonButtonWasPushed(int slot) { (6) ; } voidoffButtonWasPushed(int slot) { (7) ; }};int main() { RemoteControl* remoteControl=new RemoteControl(); Light*livingRoomLight=new Light("Living Room"); Light*kitchenLight=new Light("kitchen"); LightOnCommand*livingRoomLightOn=newLightOnCommand(livingRoomLight); LightOffCommand* livingRoomLightOff=newLightOffCommand(livingRoomLight); LightOnCommand*kitchenLightOn=new LightOnCommand(kitchenLight); LightOffCommand* kitchenLightOff=new LightOffCommand(kitchenLight); remoteControl->setCommand(0, livingRoomLightOn, livingRoomLightOff); remoteControl->setCommand(1,kitchenLightOn, kitchenLightOff); remoteControl->onButtonWasPushed(0); remoteControl->offButtonWasPushed(0); remoteControl->onButtonWasPushed(1); remoteControl->offButtonWasPushed(1); /* 其余代码省略 */ return 0;}


    答案:
    解析:
    (1)virtual void execute()=0
    (2)light->on()
    (3)light->off()
    (4)onCommands[slot]
    (5)offCommands[slot]
    (6)onCommands[slot]->execute()
    (7)offCommands[slot]->execute()

  • 第5题:

    Look! Here()the famous player

    Acomes

    Bcome 

    Chad come  

    Dcoming


    A

  • 第6题:

    【单选题】MySQL使用()文件中的配置参数。

    A.my-larger.ini

    B.my-small.ini

    C.my-huge.ini

    D.my.ini


    B