若已经声明了函数原型“void fun(int a,double b=0.0);”,则下列重载函数声明中正确的是
A.void fun(int a=90,double b=0.0);
B.int fun(int a,double B) ;
C.void fun(double a,intB) ;
D.bool fun(int a,double b=0.0);
第1题:
设有以下函数:
voidfun(intn,char}s){……}
则下面对函数指针的定义和赋值均正确的是( )。
A.void(*pf)(int,char);pf=&fun;
B.void+pf( );pf=fun;
C.void*pf( );*pf=fun;
D.void(*pf)(int,char*);pf=fun;
第2题:
设有以下函数:
void fun(int n,char*$s){……}
则下面对函数指针的定义和赋值均正确的是
A.void(*pf)( );pf=fun;
B.void*Pf( );pf=fun;
C.void*pf( ); *pf=fun;
D.void(*pf)(int,char);nf=&fun;
第3题:
已知函数fun的原型为
int fun(int,int,int);
下列重载函数原型中错误的是
A.char fun(int,int);
B.double fun(int,int,double);
C.int fun(int,char木);
D.float fun(int,int,int);
第4题:
在类A中定义了方法fun(double,int),类B继承自类A,并定义了函数fun(double),这种方式称为(46)。若B中重新定义函数fun(double,int)的函数体,这种方式称为(47)。
(62)
A.重置
B.重载
C.代理
D.委托
第5题:
设有以下函数: void fun(int n,char*s){…} 则下面对函数指针的定义和赋值均正确的是( )。
A.void(*pf)( );pf=fun;
B.void*pf( );pf=fun
C.void*pf( );*pf=fun;
D.void(*pf)(int,char);pf=&fun;
第6题:
A. fun(v1,&v2);
B.fun(v1,v2);
C.fun(&v1,v2);
D.fun(&v1,&v2);
第7题:
( 21 )已知函数 fun 的原型为
int fun ( int,int,int ) ;
下列重载函数原型中错误的是
A ) char fun ( int,int ) ;
B ) double fun ( int,int,double ) ;
C ) int fun ( int,char* ) ;
D ) float fun ( int, int, int ) ;
第8题:
若已经声明了函数原型“void fun(int a,double b=0.0);”,则下列重载函数声明中正确的是( )。
A.void fun(int a=90,double b=0.0);
B.int fun(int a,double B);
C.void fun(double a,int B);
D.bool fun(int a,double b=0.0);
第9题:
设有以下函数
void fun(int n,char * s) { …… }
则下面对函数指针的定义和赋值均是正确的是
A)void (*pf)(); pf=fun;
B)viod *pf(); pf=fun;
C)void *pf(); *pf=fun;
D)void (*pf)(int,char);pf=&fun;