Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I don't expect a complete code for the whole question, solving the first part would be great to point me out in the right direction.

image text in transcribedimage text in transcribedI don't expect a complete code for the whole question, solving the first part would be great to point me out in the right direction. Thank you!

- To view the pictures in high quality click the link below

https://drive.google.com/open?id=0B9tCsyXNJn_hZlR1bWhEWnV6ZGc

Write a C program project1.c that operates as follows. The purpose is to design a custom home by specifying the relevant dimensions and making a few other decisions, and then the program will determine the cost of building this home. The diagram below illustrates the house which will be built on a rectangular lot. You can vary the dimensions of the lot and the house. All linear dimensions will be given in feet, all areas will be calculated in and all volumes will be calculated in sq ft. All values are doubles, and all outputs should include two digits past the decimal point (use output format %0.21 f). First your program will read the following input values exactly in the order shown: Horizontal dimensions X_0, ..., X_9 and vertical dimensions Y_0, ..., Y7 in feet. All relevant dimensions of the house and lot can then be determined from the diagram. For example, the laundry has dimensions X2 by Y4, and the foyer has dimensions X5 by Y5. The only exception is that the sidewalk always has width 4, regardless the value of X5. Ceiling height Z in feet. Siding cost in dollars/sq ft. For example. vinyl=5, wood=10, brick=15, stucco=20, stone=30. Roofing cost in dollars/sq ft. For example, asphalt=3, wood=6, metal=9, clay=12, slate=15. Deck cost in dollars/sq ft. Typically 15 to 35 depending on type of wood and the deck design. Appliance style indicator. 1=aluminum, 2=stainless, 3=custom panels, etc. Flooring cost in dollars/sq ft for bathrooms, bedrooms, dining room, family room, foyer, halls, kitchen, laundry, and living room. For example, vinyl=8, carpet=10, hardwood=20, tile=25. Next your program will calculate and output the following values exactly in the order shown. Your program's output will be read and graded by another computer program (a grading script), which may not be able to recognize your output if you display it in the wrong order or label it incorrectly. Lot size in sq ft. House area in sq ft. includes garage and porches. Interior area in sq ft. Does not include garage and porches. Interior volume in cu ft. Living space that will be heated and cooled. Exterior wall length in feet. Perimeter along the boundary of the interior area. Exterior wall area in sq ft. Assume exterior height is Z+2. Wall area includes doors and windows, so do not deduct for these. The remaining outputs are in dollars and cents. Each category includes cost of materials and labor. Lot cost at exist4.00/sq ft based on lot size. Site prep at exist1.00/sq ft based on lot size. Foundation cost at exist10.00/sq ft based on house area. Framing cost at exist1.50/cu ft based on house area and exterior height. Total siding cost based on siding cost (dollars/sq ft) and exterior wall area (sq ft). Total roofing cost based on roofing cost (dollars/sq ft) and house area (sq ft). Cost of doors and windows at exist8.00 times house area. Plumbing and fixtures at exist5.00 times house area. Electrical and lighting at exist5.00 times house 3rea. Heating and A/C at exist0.50 times interior volume. Insulation at exist0.25 limes interior volume. Drywall at exist0.50 times interior volume. Painting at exist0.40 times interior volume. Cabinets at exist5.00 times interior area. Appliances allowance at exist5000.00 times the appliance style indicator. Total flooring cost based on flooring cost (dollars/sg ft) and room area (sq ft). Sum over all rooms of the house. Security system at exist0.75 times house area. Concrete at exist4.00/sq ft for driveway, patio, sidewalk, and porches. Total deck cost based on deck cost (dollars/sq ft) and deck area (sq ft). Landscaping at exist1.00/sq ft based on lawn area. Sprinkler system at exist0.30/sq ft based on lawn area. Subtotal is the sum of all above dollar amounts. Contractor adds 20% of subtotal for expenses, overhead, commissions, profit, etc. Total cost. Here is an example that shows input values and corresponding output values. Your program's outputs should be labeled and formatted exactly as shown below. Your program must read from standard input (scanf), and it must write to standard output (printf). When grading, we might redirect the input from a file, or redirect the output to a file. But your program will not be aware of this. To save typing when testing your program, you can do this too. Create an input file (such as input1.txt) that contains all the input values. Then run your program as follows:/a.out output1.txt The first command will display your program's output on the screen as usual. The second command would Instead write this output to the file output1.txt

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Time Series Databases New Ways To Store And Access Data

Authors: Ted Dunning, Ellen Friedman

1st Edition

1491914726, 978-1491914724

More Books

Students also viewed these Databases questions

Question

What are Measures in OLAP Cubes?

Answered: 1 week ago

Question

How do OLAP Databases provide for Drilling Down into data?

Answered: 1 week ago

Question

How are OLAP Cubes different from Production Relational Databases?

Answered: 1 week ago