Escolar Documentos
Profissional Documentos
Cultura Documentos
name = a;
packageID = b;
numAdults = c;
numChildren = d;
numDays= e;
numRooms = f;
return name;
return packageID;
}
public String getpackageType( String packageID)
char p = packageID.charAt(1);
if( p == 'D')
packageType = "DELUXE";
packageType ="ECONOMY";
return packageType;
char a = packageID.charAt(0);
if(a == 'K')
if(packageType == "DELUXE")
Destination = 350.00;
Destination = 220.00;
}
else if(a == 'P')
if(packageType == "DELUXE")
Destination = 470.00;
Destination = 280.00;
return Destination;
return numAdults;
return numChildren;
return numDays;
return numRooms;
return traveCost;
public double hotelCharge( String packageType, double travelCharge,int getDays, int getRooms)
if(packageType == "DELUXE"){
if(packageType == "DELUXE"){
return payDays;
return new String("{ Name = " + name +"\nPackage ID = "+ packageID +"\nNumber of Adults
= "+ numAdults +"\nNumber ofChildren = "+ numChildren +"\nNumber Of Days "
+numDays+"\nNumber of Rooms " +numRooms +"}");
}
import java.util.*;
import javax.swing.*;
char q;
Customer z;
z = new Customer();
q = sc.next().charAt(0);
count++;
a.setCustomer(name,packageID,adults,children,days,rooms);
longerst = days;
i= sc.next().charAt(0);
}
System.out.println(" The count of number customer going to Kenyir Lake under the Deluxe package
is = " + count);
if(longerst >0 ){
}
public class Box
code = c;
length = l;
width = w;
height = h;
public Box(){
code = "";
length = 0;
width = 0;
height = 0;
return code;
return length;
}
public double getWidth(){
return width;
return height;
return new String("{ code = " + code +", lenght= "+ length +", width = "+ width +",hweight =
"+ height +"}");
}
import java.util.*;
import javax.swing.*;
Box a;
int count = 0;
char q;
q=sc.next().charAt(0);
while(q == 'y')
String c = sc.next();
double l = sc.nextDouble();
double w = sc.nextDouble();
double h = sc.nextDouble();
a= new Box();
a. Box(c,l,w,h);
if(c == "07")
System.out.println(a);
double b = l * w;
count++;
q=sc.next().charAt(0);