这个if else写的太乱了,建议改成如下形式:
if(a ==0){if(x <=1)//doelse if(x>1&&x<2)//doelse//do}else if( a>0 && a<= 1){//do}else//do