QUESTION 1 [30 MARKS] Pacific Advances Services Car (PASCar) rental company wishes to update its computer system based o

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

QUESTION 1 [30 MARKS] Pacific Advances Services Car (PASCar) rental company wishes to update its computer system based o

Post by answerhappygod »

Question 1 30 Marks Pacific Advances Services Car Pascar Rental Company Wishes To Update Its Computer System Based O 1
Question 1 30 Marks Pacific Advances Services Car Pascar Rental Company Wishes To Update Its Computer System Based O 1 (207.73 KiB) Viewed 74 times
QUESTION 1 [30 MARKS] Pacific Advances Services Car (PASCar) rental company wishes to update its computer system based on class diagram in Figure 1. PASCar_App + main(arg]:String): void Car Model Persona Civic Kancil - model: String + Car(**to be complete) + carPriceRate(): double + totalRentalAmount(): double #rentalPeriod: int #earlyDropOff: boolean #lateDropOff: int #cust: Customer Table 1 Vehicle + Vehicle( **to be complete) + totalRentalAmount(): double + lateReturningFee(): double + cashRebate(): double + getCustomerName(): String Rental Rate Per Day RM 80.00 RM 65.00 RM 50.00 Figure 1 Customers can choose the from fleet of vehicles offer by PASCar for rental. Rental period is based on days and the price rate for each Car model is shown in Table 1. SUV price rate will be based on the seat number, and the price rate for SUV can be referred in Table 2. Customer -firstName: String - lastName: String + Customer(firstName: String, lastName: String) SUV -numOfSeat: int + SUV( "to be complete) + suvPriceRate(): double + totalRentalAmount(): double Number of Seats Five (5) Seven (7) Table 2 Rental Rate Per Day RM 100.00 RM 130.00 The late returning fee is recorded if the customer drop-off or return their rented vehicle later than the rented period. Lateness fee is charge based on how many hours the customer was due to return the vehicle. The late returning fee rate is shown in Table 3, but if the customer drop-off the vehicle early than the rental period, RM 10.00 cash rebate will be awarded.
Based on the all system requirement set by PASCar: a) Write a Java program that applies the Inheritance concept as Vehicle class be the Abstract class for the system (refer Figure 1 for details). [23 marks] b) In the main class, each customer data must be stored in the Array of Object and the polymorphism concept must be applies for the object declaration. Used a parameterize constructor to initialize the array. [7 marks]
Hours Overdue 1-5 6-10 11 and above First Name The formula for calculating the total rental amount is given in a Figure 2. Table 4 shows the customer data as the input for the system. Figure 3 shows an expected output for this system. John Maria Jane Emma Michael Rental Amount (RM) = Rental Period * [Car or SUV] Price Rate + Lateness Fee - Rebate Figure 2 Last Name Wick Hantucova Doe Table 3 William Obama eens Table 4 Rented Vehicle Persona SUV 7 Seats Kancil Civic SUV 5 Seats Output-HOT_1_1920_Sem_1 (run) x Full Name Rented Vehicle Model Fine RM 10.00 RM 15.00 RM 20.00 Rent Period 3 2 : John Wick <<<< Customer 2 >>>> Full Name: Car --> 3 Day (s) 5 6 1 : Persona Late Penalty Fee: RM 10.0 Rebat : RM 0.0 Rent Amount >> RM 250.0 << <<<< Customer 5 >>>> Full Name : Maria Hantucova Rented Vehicle: SUV --> 2 Day(s) Total seat 17 Late Penalty Fee: RM 0.0 Rebat : FM 10.0 Rent Amount >> RM 250.0 << Figure 3 : Michael Obama Rented Vehicle: SUV --> 1 Day (5) Total seat :5 Late Penalty Fee: RM 0.0 Rebat : FM 10.0 Rent Amount >> RM 90.0 << Late Drop-off 3 0 0 12 0 Early Drop-off NO YES YES NO YES
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply