A.template<typenameT>voidswap(Ta[],Tb[],intsize);
B.template<typenameT>voidswap(intsize,Ta[],Tb[]);
C.template<typenameT1,typenameT2>voidswap(T1a[],T2b[],intsize);
D.template<classT1,classT2>voidswap(T1all,T2b[],intsize);
[单选题]已知主函数中通过如下语句序列实现对函数模板swap的调用:int a[10], b[10];swap(a, b, 10);下列对函数模板swap的声明中,会导致上述语句序列发生编译错误的是( )。A.) template<typename T>void swap(T a[], T b[], int size);B.) template<typename T>void swap(int size, T a[], T b[]);C.) template<typename T1, typename T
[单选题]有如下函数模板:template
[单选题]若有以下函数首部int fun(double x[10],int*n)则下面针对此函数的函数声明语句中正确的是( )。A.intfun(double
[单选题]有如下函数模板:template
[单选题]有如下函数模板:TemplateT cast(U u)(return u;其功能是将U类型数据转换为T类型数据。已知i为int型变量,下列对模板函数c
[单选题]已知函数fun的原型为int fun(int,int,int);下列重载函数原型中错误的是( )。A.charfun(int,int);B.doub
[单选题]若有函数模板mySwap和一些变量定义如下:template
[单选题]设有某函数的说明为int* func(int a[10], int n);则下列叙述中,正确的是( )。A.形参a对应的实参只能是数组名B.说明中的
[单选题]有如下函数模板定义:template
[单选题]有以下函数:#include