Write a Java program correctly that generates a receipt for a delivery company, called “Montréal DeliveryExpress” that delivers goods to its clients. The company is located in Montréal and operates onlyin Québec.Write a program which:1. Display a welcome message.2. Then prompts the user to enter the following• First name of the client.• Last name of the client.• Address of the client (include street number, street name and apt number if applicable).• City of the client.• Postal code of the client.• Day of delivery.• Month of delivery.• Year of delivery.• Distance from source to destination in kilometers.• Value of the goods to be delivered.3. Generate the receipt based on the information entered by the user above, see a sample outputin the next page. First the receipt should display the Company name followed by the deliverydate. Then, the first name and last name of the client. The first letter in first name and last nameshould be displayed in Upper Case letters and the rest should be displayed in Lower Caseletters. Then, the full address should be displayed (include street, city, province and postalcode). Province should be displayed as QC and Postal code should be displayed in Upper Caseletters. Next, the value of the goods should be displayed followed by the delivery fees, thenthe TPS value, then the TVQ value and finally the Total value of the bill.The delivery fees are calculated based on the distance from the source to the destination whereeach kilometer is charged 55 cents.The TPS is calculated based on the sum of the value of goods and the delivery fees with a rateof 5%.The TVQ is calculated based on the sum of the value of the goods and the delivery fees with arate of 9.975%.The total of the bill is calculated based on the sum of the value of the goods and the deliveryfee and the TPS value and the TVQ value.The TPS and TVQ numbers associated with the company should be displayed on the receiptwith values 12345 6789 RT0001 and 1234567890 TQ0020 respectively.For example, if sub total is 100 $, and distance is 10 KM, thenDelivery Fees = 10 * 0.55 = 5.5TPS = (100 + 5.5) * 0.05 = 105.5 * (5 / 100) = 5.28TVQ = (100 + 5.5) * 0.09975 = 105.5 * (9.975 / 100) = 10.52Total = 100 + 5.5 + 5.28 + 10.52 = 121.3
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here