设有定义: class person {int num; char name[10]; public: void init(int n,char*m) }; personstd[30] 则以下叙述不正确的是( )。A.std是一个含有30个元素的对象数组B.std数组中的每个元素都是person类的对象C.std数组中的每个元素都有自己的私有变量num和nameD.std数组中的每个元素都有各自的成员函数init

设有定义: class person {int num; char name[10]; public: void init(int n,char*m) }; personstd[30] 则以下叙述不正确的是( )。

A.std是一个含有30个元素的对象数组

B.std数组中的每个元素都是person类的对象

C.std数组中的每个元素都有自己的私有变量num和name

D.std数组中的每个元素都有各自的成员函数init


相关考题:

设有以下函数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;

有以下程序:includeincludeusingnameSpacestd;classperson{ intage; Char*nam 有以下程序:include <iostream>include <string>using nameSpace std;class person{int age;Char * name;public:person ( int i, Char * str ){int j;j = strlen( str ) + 1;name = new char[ j ];strcpy( name, str );age = i;}~person(){delete name;cout<<"D";}void display(){cout<<name<<":"<<age;}};int main(){person demo( 30,"Smith" );demo.display();return 0;}则该程序的输出结果为:【 】。

用于定义类成员的访问控制权限的一组关键字是A.extends 和 implementsB.public,private 和 protectedC.class和publicD.char,int,float和double

设有以下函数: void fun(int n,char*s){…} 则下面对函数指针的定义和赋值均正确的是( )。A.void(*pf)( );pf=fun;B.void*pf( );pf=funC.void*pf( );*pf=fun;D.void(*pf)(int,char);pf=fun;

设有定义:Class person{ int num; char name[10]; public: void init(int n,char*m);…};person std[30]则以下叙述不正确的是A.std是一个含有30个元素的对象数组B.std数组中的每个元素都是person类的对象C.std数组中的每个元素都有自己的私有变量num和nameD.std数组中的每个元素都有各自的成员函数init

设有定义: classperson {inthum; charname[10]; public: voidinit(intn,char*m); }; personstd[30] 则以下叙述不正确的是( )。A.std是一个含有30个元素的对象数组B.std数组中的每个元素都是person类的对象C.std数组中的每个元素都有自己的私有变量num和nameD.std数组中的每个元素都有各自的成员函数init

设有以下函数: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;

设有以下函数: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;

设有以下定义:class person{int num;char name[10];public:void init (int n, char *m);┇};person std [30];则下面叙述中,不正确的是( )。A.std是一个含有30个元素的对象数组B.std数组中的每个元素都是person类的对象C.std数组中的每个元素都有自己的私有变量num和nameD.std数组中的每个元素都有各自的成员函数init