C++出现问题 error C2181: illegal else without matching if
C++出现问题 error C2181: illegal else without matching if
日期:2017-09-21 15:54:49 人气:1
1、illegal else without matching if
意思是if 和 else不匹配,一个if配一个else。
2、例如:
if(x>=1)
y=500;
→else if(x>=0)
y=0;
else y=-500;
去掉y=500;前的 { 和else y=-500;下一行的}就可以了,