C++ LANGUAGE Your project name as well as your source file name should be descriptive and contain YOUR name too (exampl

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

C++ LANGUAGE Your project name as well as your source file name should be descriptive and contain YOUR name too (exampl

Post by answerhappygod »

C++ LANGUAGE

Your project name as well as your source file name should be
descriptive and contain YOUR name too (example:
“Arrays Quiz (H. Delta)”)


2.Your program should:

Have the “usual” initial comments as stated in class
have a title that contains the project name and
your name in the title bar (similar to
mine)
print a banner similar to mine
nicely centered
Change to background color and fond color to an easy to read
color scheme.


General Purpose: Your program should find how
many items each customer bought, what is the total amount to pay
and what amount he/she saved
Your program should print a banner
Your program should handle infinite number of
customers
For each customer your program should ask for
the price of a product
You do NOT have to validate if the user enters
a numeric value. Let the program crash if that situation
occurs,
but do NOT let the program crash if the users
enters something like “10 dol”.

If a negative price is given that means this
customer’s order is done (sentinel terminated loop)
If the price is not negative then your program
should ask for the discount percentage of that
item,
The discount is an integer (like 20%).
Make sure that the user enters a valid
discount. Discount can NOT be negative or
more than 100% or have decimal places. As always, have the
validation in function(s) NOT in the main. Follow the rules for
input validation functions that are in the course website.


After an acceptable discount is entered your program should
state:

the price,
the discount,
the savings and
how much the customer has to pay for that specific item. See
sample exe for formatting requirements.


10.Then your program should ask the price for the
next item and repeat the process until a negative
price is entered.
11.The above signals the end of that customer’s
order so your program should report:

the total amount the customer has to pay for his order,
how many items he bought and
how much money he saved in total


12.The program should ask for the price of the first item of
the next customer and so on forever.
13.Make sure your code loops infinitely to allow multiple
checks
14.Do a full check of your program including the extreme
situations:

What if a customer bought nothing (negative price is entered
for his first item?)
What if he bought only one item (observe the grammar,
singular vs plural)
How many decimal places do you need to display for money?


15.Make sure your prompts and errors messages are like mine in
ALL situations
16.Make sure you have the appropriate types and names for your
variables (short, descriptive, not misleading and following the
naming conventions for naming identifiers)
17.Make sure you use validation functions for
EVERY input. Don’t forget that a function can call
another function. Avoid by reference variables unless you have no
choice.
18.Hint: You do NOT need
arrays nor vectors for this quiz!
19.Have any functions that print to be able to print to
a file as well, even though you don’t print to a file for this
quiz!
20.Try not to make your solution more complicated than it needs
to be. As a guideline, my solution including comments is 88 lines,
98 with the extra credit. Note that I don’t have the open curly
brackets in a separate line.
21.Make sure when it is printed each statement can fit in one
line. To do so make sure you don’t have any code after column
101.
22.Your program should compile in debug mode with
NO errors and NO warnings.
23.Do not forget that code
design/formatting/clarity/readability is part of
your grade (did you use the appropriate “tool” for each
situation?
24.Do not forget that output
design/formatting/clarity/readability is part of
your grade (both console as well file output)
25.Do not forget to make your project
release
26.Go over each bullet to ensure that you have not missed a
requirement.
27.Do not forget to test the .exe thoroughly
and compare your solution with mine.
28.Make sure you follow or the “should” and design rules
mentioned this semester and/or are listed on the course
website.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply