Assignment2.py - Michelle Gong Section 03 Assignment#2 This is a program that calculates the cost of building a bunker according to customer

Assignment2.py - Michelle Gong Section 03 Assignment#2 This...

This preview shows page 1 - 2 out of 2 pages.

# Michelle Gong # Section 03 # Assignment #2 # This is a program that calculates the cost of building a bunker according to # customer specifications # 10/8/19 # named constants # things we already know OPENING_SURFACE = 1.2 * 1.9 #in meters WALL_THICKNESS = 1.5 #in meters DENSITY = 2500 #in kg/m^3 LABOR_COST = 90.64 #in dollars per square meter of surface area # input section # asking the user for measurements message = ('Please enter the overall bunker length in meters: ') length = float(input(message)) message = ('Now please enter the overall bunker width in meters: ') width = float(input(message)) message = ('Lastly, please enter the overall bunker height in meters: ') height = float(input(message)) # processing section # performs calculations wall_thickness_2 = WALL_THICKNESS * 2 ext_volume = length * width * height # in cubic meters int_volume = (length - wall_thickness_2) \ * (width - wall_thickness_2) \ * (height - wall_thickness_2) # in cubic meters ext_surface_area = 2 * (length * width \ + width * height \ + height * length) \ - OPENING_SURFACE # in cubic meters int_length = length - wall_thickness_2
Image of page 1
Image of page 2

You've reached the end of your free preview.

Want to read both pages?

  • Spring '16
  • goldner barbara

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Stuck? We have tutors online 24/7 who can help you get unstuck.
A+ icon
Ask Expert Tutors You can ask You can ask ( soon) You can ask (will expire )
Answers in as fast as 15 minutes
A+ icon
Ask Expert Tutors