主观

#include ﹤ iostream.h ﹥

template ﹤ class T ﹥

class f{

private: T x, y;

public: void f1(T a,T b){x=a;y=b;}

T max( ){retum(x﹥y)? x:y;}

};

void main( ){

f ﹤int﹥a;a. f1(3.5,3.8) ;

cout ﹤﹤ a. max( ) ﹤﹤ endl;

}

参考答案
您可能感兴趣的试题
¥

订单号:

遇到问题请联系在线客服

订单号:

遇到问题请联系在线客服