|
CS-182 -- Lab 2: Income Calculation Winter Quarter 1999-2000 Electrical Engineering and Computer Science Department CC-27C, 277-7339 PurposeIn this lab, you will write your first C++ program. When done, you should be able to declare objects as well as understand the functionality of the cin and cout objects. AssignmentWrite a program that computes the number of seconds between payments if the user was paid in one penny increments. Your program should prompt the user for his/her yearly salary and the number of vacation days he/she gets each year. You should assume that the user works 40 hours per week. Your program should then produce the following output (on the screen): I did some math on your salary today, and it turns out that you get a penny every XXX seconds. I'm kind of glad they save it all for the end of the week, though. where XXX is replaced with the appropriate number of seconds. Programming consideration: It is always good in program design to consider potential modifications that may be required a some later date. Be sure to keep this in mind when designing your program. QuestionsYou should provide answers to the following questions in your report:
Lab report (due 11:00pm, the day prior to week 4 lab)The lab report should be self-contained. That is, it should be possible for someone to understand what you did and why without seeing anything other than your report. Your report should include:
As with any report you submit, correct spelling and grammar are required. In addition, your report should be submitted electronically following the Electronic submission guidelines. (You may wish to consult the sample report before submitting your report.) Be sure to keep copies of all your files, in case something gets lost. It may be wise to keep a diskette backup as well. If you have any questions, consult the instructor. This page was created by Dr. Christopher C. Taylor, copyright 1999. |