下列程序输出结果是【】。 include using namespace std; template T fun( 下列程序输出结果是【 】。include <iostream>using namespace std;template <typename T>T fun(T a, T b) {return (a<=b)?a:b;}int main(){cout<<fun(3,6)<<','<<fim(3.14F, 6.28F)<<end 1;return 0;}
下列程序输出结果是【】。 include using namespace std; template T fun(
下列程序输出结果是【 】。
include <iostream>
using namespace std;
template <typename T>
T fun(T a, T b) {return (a<=b)?a:b;}
int main()
{
cout<<fun(3,6)<<','<<fim(3.14F, 6.28F)<<end 1;
return 0;
}
相关考题:
下列程序的输出结果是()。includeusing namespace std;templateT fun(T a 下列程序的输出结果是( )。 #include<iostream> using namespace std; template<typename T> T fun(T a,T b){return(a>=b)?a:b;} void main() { cout<<fun(3,6)<<','<<fun(3.14F,6.28F)<<end1; }A.6,3.14B.3,6.28C.3,3.14D.6,6.28
有如下程序:includevoid fun(intx, int y){int t=x; x=y; y=t;}int main(){int 有如下程序: #include<iostream> void fun(intx, int y){int t=x; x=y; y=t;} int main() { int a[2]={23,42}; fun(a[1],a[0]); std::cout<<a[0]<<","<<a[1]<<std::end1; return 0; } 执行后的输出结果是( )。A.42,42B.23,23C.23,42D.42,23
下列程序的输出结果是【】。 inClude rsing namespace std; template T fun( 下列程序的输出结果是【 】。inClude<iostream>rsing namespace std;template<typename T>T fun(Ta,Tb){retum(a<=b)?a:b;)int main(){cout<<fun(3,6)<<','<<fun(3.14F,6.28F)<<endl; .return 0;}
有如下程序:include void fun (int x,int y){int t=x;x=y;y=t;}int main(){ int 有如下程序: #include <iostream> void fun (int x,int y){int t=x;x=y;y=t;} int main() { int a[2]={23,42}; fun (a[1],a[0]; std::cout<<a[0]<<”,”<<a[1]<<std:: ond1; retum0; }执行后的输出结果是______ 。A.41,41B.23,23C.13,42D.42,23
下列程序的输出结果是【】 includeusing namespace std; template T total 下列程序的输出结果是【 】include<iOStream>using namespace std;template <typename T>T total (T*datA){T s=0;while(*datA){s+=*data++;}return s;}int main(){int x[]={2,4,6,8,0,12,14,16,18};cout<<total(x)<<end1;return 0;}
有如下程序: include void fun(intx,int y){int t=x;x=y;y=t;} int ma 有如下程序: #include<iostream> void fun(intx,int y){int t=x;x=y;y=t;} int main() { int a[2]={23,42}; fun(a[1],a[0]; std::cout<<a[0]<<","<<a[1]<<std::ndl; return 0; } 执行后的输出结果是A.42,42B.23,23C.23,42D.42,23
有如下程序:include void fun(int x, int y){int t=x;x=y;y=t;}int main (){int 有如下程序: #include <iostream> void fun(int x, int y){int t=x;x=y;y=t;} int main () { int a[2]={23,42}; fun(a[1],a[0]); std::cout<<a[0]<<","<<a[1]<<std::endl; return 0; } 执行后的输出结果是A.42,42B.23,23C.23,42D.42,23
如下程序的输出结果是includevoid fun(int x=y;y=t;}int main(){in 如下程序的输出结果是 #include<iostream> void fun(int & X,inty){intt=x;x=y;y=t;} int main( ){ int a[2]={23,42}; fun(a[1],a[0]); std::cout<<a[0]<<","<<a[1]<<std::endl; return 0; }A.42,42B.23,23C.23,42D.42,23
以下程序的输出结果是【 】。includeincludechar*fun(char*t){ char *p=t;retur 以下程序的输出结果是【 】。include <stdio.h>include <string.h>char *fun(char *t){ char *p=t;return (p+strlen(t)/2);}main(){ char *str="abcdefgh";str=ftm(str);puts(str);}