欢迎来到牛牛题库网 牛牛题库官网
logo

单项选择题

Class Stonewt is declared as follows. 
class Stonewt
{
   //some members
public:
    Stonewt(double lbs);
    Stonewt(int stn, double lbs);
    Stonewt();
    ~Stonewt();
    operator int() const;
    operator double() const;
};
Which function will be invoked by the following line of code ?
wt = 120.0; //wt is an object of type Stonewt

A. Stonewt(double lbs);
B. Stonewt();
C. operator int() const;
D. operator double() const;
点击查看答案&解析
微信小程序免费搜题
微信扫一扫,加关注免费搜题

微信扫一扫,加关注免费搜题