How to avoid too many if else statements

I am writing a simple app using matlab app designer, My code works but I want to make it better. I have too many if else conditions. How can I avoid this?

 function buttonpush3Act(app, event)         a3= app.StrokeLengthmmEditField_13.Value;         b3=app.StrokeLengthmmEditField_12.Value;         c3= app.StrokeLengthmmEditField_11.Value;         d3=app.BuildingDimensionmmEditField_6.Value;         e3=app.BuildingDimensionmmEditField_5.Value;         f3=app.BuildingDimensionmmEditField_4.Value;         g3=app.orPreconfiguredrefnumEditField.Value;         h3=app.orPreconfiguredrefnumEditField_2.Value;         i3=app.orPreconfiguredrefnumEditField_3.Value;         j3=app.ActuatorTypeNumberEditField.Value;         k3=app.ActuatorTypeNumberEditField_2.Value;         l3=app.ActuatorTypeNumberEditField_3.Value;           %reset message field         app.OutputMessageEditField_2.Value= "";         % avoid missuse of the ┬┤result┬┤button         if(a3==0 && b3==0 && c3==0 && d3==0 && e3==0 && f3==0 && g3==0 && h3==0)             app.Actuator1EditField.Value= '';             app.Actuator2EditField.Value= '';             app.Actuator3EditField.Value ='';             app.OutputMessageEditField_2.Value ='';              %check for pre configured actuators            elseif((j3== k3 == l3 || j3== k3 || j3== l3 || k3 == l3) && (j3 > 0 && k3 > 0 && l3 > 0)) %avoid having more than one LA40             app.Actuator1EditField.Value= '';             app.Actuator2EditField.Value= '';             app.Actuator3EditField.Value ='';             app.OutputMessageEditField_2.Value =" ERROR2: Unsupported configuration";              %check if special actuators present         elseif((j3 == 40 && k3 ~= 40 && l3 ~= 40) || (j3 ~= 40 && k3 == 40 && l3 ~= 40) || (j3 ~= 40 && k3 ~= 40 && l3 == 40))             % a rotation to to catch la 40 and define it as ref4             dataLa40 = [j3,k3,l3];             ref4 = dataLa40(1)             for r= 1:length(dataLa40)                 if dataLa40(r) == 40;                     ref4 = dataLa40(r);                 end             end             if (ref4 == dataLa40(1))                app.Actuator1EditField.Value = "ref4";             elseif(ref4 == dataLa40(2) )               app.Actuator2EditField.Value = "ref4";             else(ref4 == dataLa40(3))                 app.Actuator3EditField.Value = "ref4";             end              %  if act1== ref4 what if act2== ref4 what if act3== ref4 what           %check for rule D           elseif((a3 ~= b3) && (a3~= c3) && (b3 ~= c3) && (a3 > 0 && b3 > 0 && c3 > 0))              data= [a3,b3,c3];             ref2= data(1)             ref3=data(1)             ref1=data(1)             for j = 1:length(data)                 %largest stroke length                 if data(j)>ref2;                     ref2=data(j);                 end             end             for k = 1:length(data)                 %smallest stroke length                 if data(k)<ref3;                     ref3=data(k);                 end             end              for m = 1:length(data)                 %stroke length in the middle                 if ref3<data(m) & data(m)<ref2;                     ref1=data(m);                 end             end              if (ref2== a3)                 app.Actuator1EditField.Value= "ref2"  ;             elseif(ref2==b3)                 app.Actuator2EditField.Value= "ref2"  ;             else(ref2==c3)                 app.Actuator3EditField.Value= "ref2"  ;             end             if(ref3==a3)                 app.Actuator1EditField.Value= "ref3"  ;             elseif(ref3==b3)                 app.Actuator2EditField.Value= "ref3"  ;             else(ref3==c3)                 app.Actuator3EditField.Value= "ref3"  ;             end             if(ref1==a3)                 app.Actuator1EditField.Value= "ref1"  ;             elseif(ref1==b3)                 app.Actuator2EditField.Value= "ref1"  ;             else(ref1==c3)                 app.Actuator3EditField.Value= "ref1"  ;             end             % elseif((a3 == b3) || (a3 == c3) || (b3 == c3))             %check for rule C         else(((a3 == b3) || (a3 == c3) || (b3 == c3)) && (a3 > 0 && b3 > 0 && c3 > 0))              data_list= [d3,e3,f3];             ref2= data_list(1)             ref3=data_list(1)             ref1=data_list(1)             for n = 1:length(data_list)                 %largest Building Dimension                 if data_list(n)>ref2;                     ref2=data_list(n);                 end             end             for p = 1:length(data_list)                 %smallest Building Dimension                 if data_list(p)<ref3;                     ref3=data_list(p);                 end             end              for q = 1:length(data_list)                 %Building Dimension in the middle                 if ref3<data_list(q) & data_list(q)<ref2;                     ref1=data_list(q);                 end             end                if (ref2== d3)                 app.Actuator1EditField.Value= "ref2"  ;             elseif(ref2==e3)                 app.Actuator2EditField.Value= "ref2"  ;             else(ref2==f3)                 app.Actuator3EditField.Value= "ref2"  ;             end             if(ref3==d3)                 app.Actuator1EditField.Value= "ref3"  ;             elseif(ref3==e3)                 app.Actuator2EditField.Value= "ref3"  ;             else(ref3==f3)                 app.Actuator3EditField.Value= "ref3"  ;             end             if(ref1==d3)                 app.Actuator1EditField.Value= "ref1"  ;             elseif(ref1==e3)                 app.Actuator2EditField.Value= "ref1"  ;             else(ref1==f3)                 app.Actuator3EditField.Value= "ref1"  ;             end              %check for eqaul building dimentions             if(((d3 == e3) || (d3 == f3) || (e3 == f3)) && (d3 > 0 && e3 > 0 && f3 > 0))                 app.OutputMessageEditField_2.Value ="Use channel assignment or config. tool";                 app.Actuator1EditField.Value= '';                 app.Actuator2EditField.Value= '';                 app.Actuator3EditField.Value ='';              else                 app.OutputMessageEditField_2.Value ="ERROR2; Fill the required fields";                 app.Actuator1EditField.Value= '';                 app.Actuator2EditField.Value= '';                 app.Actuator3EditField.Value ='';              end         end          %should be out of main loop, independent         if(a3 == 0 ||b3 == 0 ||c3 == 0 ||d3 == 0 ||e3 == 0 ||f3 == 0 ||j3 == 0 ||k3 == 0 ||l3 == 0 )             app.OutputMessageEditField_2.Value ="ERROR2; Fill the required fields";             app.Actuator1EditField.Value= '';             app.Actuator2EditField.Value= '';             app.Actuator3EditField.Value ='';         end     end 

Anybody Else Hosting On Bluehost?

I've had my websites hosted in BlueHost for 4 years now. For the first year they offered me a dirt cheap deal, something like 60 bucks / year, they then jacked the price up to 119 $ / year for the next 3 years, and this November, when I was about to renew my hosting I had the unpleasant surprise of finding out they had jacked up my price again by about 30 bucks.
Are any of you hosting on BlueHost, and has that happened to you as well?

Q : Loops along with If-statements & else if statements | Rental Car Calculator Project (WHOLE DAYS ONLY)

At the prompt: “System.out.print(“What vehical would you like to rent?\n”); ” I can not figure out why when a number that is not 1-3 is entered it will not repeat the loop as I want OR display any input I’ve entered for the system.print

Second, I can not figure how to make an if statement only allowing the user to enter 1 or 0 when prompted: “System.out.println(“If there are any customer press 1 else press 0″);” Without making an error in my loop for summary data or counts.

package inter;  import java.util.InputMismatchException; import java.util.Scanner;  public class Inter { public static void main(String []args){ int count=0; int days; double DailyFee=0, NontaxTotal, CarType, Total,FullTotal=0; boolean F1 = false, F2 = false; Scanner in=new Scanner(System.in); System.out.println("If there are any customer press 1 else press 0"); int cus=in.nextInt();      while(cus!=0){         while(F1 == false) {             F1 = true;             count++;             System.out.print("What vehical would you like to rent?\n");             System.out.println("Enter 1 for an economy car");             System.out.println("Enter 2 for a sedan car");             System.out.println("Enter 3 for an SUV");             CarType = in.nextInt();             try {                 CarType = in.nextInt();                 if (CarType <= 0 || CarType >= 4) {                     System.out.print("Number must be 1-3\n");                     System.out.println("Please enter 1 for an economy car");                     System.out.println("Enter 2 for a sedan car");                     System.out.println("Enter 3 for an SUV");                     CarType = in.nextInt();                     F1 = false;                 } else {                      if (CarType == 1) {                          F1 = true;                           DailyFee=31.76;                 } else if(CarType == 2) {                         F1 = true;                           DailyFee=40.32;                 } else if(CarType == 3) {                         F1 = true;                           DailyFee=47.56;                 }                 while (F2 == false) {                     F2 = true;                     try {                          System.out.print("Please enter the number of days rented. (Example; 3) : ");                         days = in.nextInt();                          if (days <= 0) {                             System.out.println("Number of days must be more than zero");                             F2 = false;                         } else {                             days = in.nextInt();                             double x=days;                             NontaxTotal = (DailyFee * x);                             Total = (NontaxTotal * 1.06);                             FullTotal+=Total;                         }                     } catch(InputMismatchException ex) {                         System.out.println("Answer must be a number");                         F2 = false;                         in.next();                         }                     }                 }             } catch (InputMismatchException ex) {                 F1 = false;                 System.out.println("Answer must be a number");              }         }      }     in.close();     System.out.println("Count of customers : "+count);     System.out.printf("Total of the Day : $   %.2f",FullTotal); } 

}