填空题

结构化程序设计方法的主要技术是 【5】 、逐步求精。

【参考答案】

自顶向下
<上一题 目录 下一题>
热门 试题

单项选择题
有如下程序:#include <iostream>using namespace std;class Obj static int i;public: Obj()i++; -Obj()i--; static int getVal()return i; ;int Obj::i=0;void f()Obj ob2; cout<<ob2.getVal(); hat main() Obj ob1; f(); Obj *ob3=new Obj; cout<<ob3->getVal(); delete ob3; cout<<Obj:: getVal(); return ();程序的输出结果是( )。
A.232
B.231
C.222
D.221
单项选择题
有如下程序:#include <iostream>using namespace std;class Baseprivate: char c;public: Base(char n):c(n) ~Base() cout<<c;;class Derived: public Baseprivate: char c;public: Derived(char n):Base(n+1),c(n) ~Derived() cout<<c;;int main() Derived obj(’x’); return 0;执行上面的程序将输出( )。
A.xy
B.yx
C.x
D.y
相关试题
  • 在下面的程序的横线处填上适当的语句,使该...
  • 【14】 允许用户为类定义一种模式,使得...
  • 请将下列类定义补充完整。class Base pub...
  • 重新定义标识符的作用域规定是外层变量被隐...
  • 阅读下面程序:#include <iostream.h>...