
C++中结构体可以直接比较吗
比如定义了structstudent{stringname;doublescore;};然后有studenta,b;if(a==b)//这句可以吗?不能直接,可以用什么方...
比如定义了struct student{ string name; double score; }; 然后有student a,b; if(a==b) //这句可以吗? 不能直接,可以用什么方法呢? ......
展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询