Automotive Exam Project
docx
keyboard_arrow_up
School
Florida Atlantic University *
*We aren’t endorsed by this school
Course
COP3450
Subject
Industrial Engineering
Date
Jan 9, 2024
Type
docx
Pages
5
Uploaded by AgentAnteaterPerson953
Automotive Exam Project
You are a programmer working for a company that creates programs for local businesses.
Eddies Automotive and Tire Shop is looking for a new program that will calculate the total price
of the cost of repair to a car. Your company interviewed Eddy and he wanted these specifics for
the program:
-
It must be professional and look well organized.
-
It must include the name of the company
-
It must make sense and flow well
-
It must have user input
-
The output must be written nicely and include this disclaimer at the bottom:
-
The prices above represent an ESTIMATED amount and the final price may be
adjusted upon analyzing and running diagnostics on the vehicle provided.
-
The output numbers must have comma separators and rounded to the 2nd decimal point
with a $ symbol with the price.
-
The services provided with prices are:
-
Tire rotation: $25
-
Oil change: $50
-
Collision repair: $1,500 - 5,000
-
Tire repair: $25
-
General repair: $100-$1,000
-
State Inspections: $30
-
Diagnostic repairs: $250-500
-
The user should input their price if they plan on using that service. For services that
won’t be used, the user can input $0.
The total must include a 6% tax and output in a sentence. There must be the name of the
company and a welcome message outputted in the beginning of the prompting the user what to
do. An example is given below:
Welcome to Eddie's Automotive and Tire Shop! We are happy to be serving you today.
Below, you will choose the services you want for today. The services we provide with the prices
are:
Tire Rotation: $25
Oil change: $50
Collision repair: $1,500 - 5,000
Tire repair: $25
General repair: $100-$1,000
State Inspections: $30
Diagnostic repairs: $250-500
Rubric:
A
-
Program code runs properly without
any errors
-
Program is very well detailed and
looks professional
-
Program has all elements required by
the client
-
Program has advanced elements
discussed in class (operators, f
strings, methods, etc.)
B
-
Program code runs properly without
any errors
-
Program is fairly detailed and looks
presentable
-
Program has most elements required
by the client
-
Program displays advanced
programming concepts
C
-
Program code runs properly without
any errors
-
Program displays some detail but
does not flow with the program
-
Program has some elements required
by the client
-
Program displays basic programming
concepts
D
-
Program code mostly runs with minor
errors
-
Program doesn’t display in a
professional manner
-
Program have very little required by
client
-
Low level programming displayed
F
-
Program doesn’t run
-
Program doesn’t follow any type of
layout or display professionalism
-
1 or 2 items from client are displayed
-
Extremely basic programming skills
**Extra Credit**
You will receive extra credit for using 1 or more if statements. You may use the link below for
help:
https://www.w3schools.com/python/gloss_python_if_statement.asp
# Constants for service prices
tire_rotation_price = 25.00
oil_change_price = 50.00
collision_repair_price_range = (1500.00, 5000.00)
tire_repair_price = 25.00
general_repair_price_range = (100.00, 1000.00)
state_inspections_price = 30.00
diagnostic_repairs_price_range = (250.00, 500.00)
# tax rate
tax_rate = 0.06
# Company name
company_name = "Eddie's Automotive and Tire Shop"
# Welcome message
print(f"Welcome to {company_name}! We are happy to be serving you today.")
# Display available services and prices
print("\nBelow, you will choose the services you want for today. The services we provide with the
prices are:")
print(f"tire rotation: ${tire_rotation_price:.2f}")
print(f"oil change: ${oil_change_price:.2f}")
print(f"collision repair: ${collision_repair_price_range[0]:.2f} - $
{collision_repair_price_range[1]:.2f}")
print(f"tire repair: ${tire_repair_price:.2f}")
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
print(f"general repair: ${general_repair_price_range[0]:.2f} - $
{general_repair_price_range[1]:.2f}")
print(f"state inspections: ${state_inspections_price:.2f}")
print(f"diagnostic repairs: ${diagnostic_repairs_price_range[0]:.2f} - $
{diagnostic_repairs_price_range[1]:.2f}")
# Initialize total cost
total_cost = 0.0
# Ask the user to input the cost for each service
total_cost += float(input("\nEnter the cost for Tire Rotation (Enter 0 if not selected): $"))
total_cost += float(input("Enter the cost for Oil change (Enter 0 if not selected): $"))
collision_repair_cost = float(input("Enter the cost for Collision repair (Enter 0 if not selected): $"))
total_cost += collision_repair_cost
total_cost += float(input("Enter the cost for Tire repair (Enter 0 if not selected): $"))
general_repair_cost = float(input("Enter the cost for General repair (Enter 0 if not selected): $"))
total_cost += general_repair_cost
total_cost += float(input("Enter the cost for State Inspections (Enter 0 if not selected): $"))
diagnostic_repairs_cost = float(input("Enter the cost for Diagnostic repairs (Enter 0 if not
selected): $"))
total_cost += diagnostic_repairs_cost
# Calculate the tax amount
tax_amount = total_cost * tax_rate
# Calculate the total cost including tax
total_cost_with_tax = total_cost + tax_amount
# Display the total cost in a nicely formatted sentence
print("\nThank you for choosing our services at", company_name)
print(f"Your total cost, including tax, is: ${total_cost_with_tax:.2f}")
# Disclaimer
print("The prices above represent an estimated amount, and the final price may be change after
analyzing the vehicle.")