public class CalParkingFee { int ptime; static double fee; static double parkingfee(double entrytime, double exittime) { //Math.ceil(0.5); 소숫점 올림 //Math.floor(1.2); 버림 //Math.round(1.4)...
... public class CalParkingFee { public static double calculateFee(double ptime) { double fee = 0; return fee; } public static void main(String[] args) { double entrytime; double exittime; double fee; String flag; Scanner scan...
... public class CalParkingFee { public static void main(String args[]){ Scanner s = new Scanner(System.in); // scanner 클래스를 새로 받는다. System.out.print("차가 들어온 시간>> "); CarIn ci = new CarIn(s.nextInt...
... class CalParkingFee { static double Caltime(double itime, double otime) { double time, fee ; time=Math.ceil(otime... return fee; } public static void main(String[] args) { double in, out; String flag="y"; Scanner scan = new Scanner...
-
... public class ParkingFeeTest { static double CalParkingFee(double PTime, double pointTime) { if(PTime<=1.0) { return 1000.0; } else if(1.0<PTime<=18.0 && pointTime>0) { return(1000.0+((int)PTime-1.0)*500.0+500.0); } else if(18.0...
... public class CalParkingFee { public static double calculateFee(double ptime) { double fee = 0; return fee; } public static void main(String[] args) { double entrytime; double exittime; double fee; String flag; Scanner scan...
... public class CalParkingFee { // 주차 시간이 주어지면 주차요금을 계산한다.(calculateFee) // @입력 매개변수들: // ptime - 주차시간 // @되돌려주는 값: 주차요금 // 여기에 코드를 삽입하세요 public static void main(String...