Advertisement
Advertisement
| 04.19.2008 at 08:05AM PDT, ID: 23336629 |
|
[x]
Attachment Details
|
||
|
[x]
The Solution Rating System
|
||
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.
Your Input Matters If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: |
#include <stdio.h>
#include <math.h>
int main()
{
/* declare variables for each part we need */
double price;
double taxPriceD;
double taxPrice2E;
double taxPrice3L;
double fullPriceD;
double fullPrice2E;
double fullPrice3L;
printf ("Enter sale price: "); /* print request on screen */
fflush (stdin);
scanf( "%.2f" ,&price); /*ask for user input */
//if (price <= 2)
//{
// printf ("ERROR \n"); /* if the amount is not valid then beep and ask again */
//main();
//}
//else
//{
/* calculate sales tax for each store */
Printf ( tax caluculation\n\n)
//enter variables
taxPriceD = price * 0.0725;
taxPrice2E = price * 0.075;
taxPrice3L = price * 0.0775;
/* using sales tax and amount entered by user, find the total sale amount for that particular purchase */
fullPriceD = price + taxPriceD;
fullPrice2E = price + taxPrice2E;
fullPrice3L = price + taxPrice3L;
/* print to the screen the results for each store with the same purchase amount */
printf ("The total price at Del Mar would be $ " %.2f \n\n ,fullPriceD);
printf ("The total price at Encintias would be $ " %.2f \n\n ,fullPrice2E);
printf ("The total price at La Jolla would be $ " %.2f \n ,fullPrice3L);
/* message to show program is finished */
printf ("\n\t\t\a\aThank you for choosing Kudler Fine Foods! \n\n\n");
printf ("\nThe program is complete, press any key to finish!\n");
getch();
return 0;
}
|