Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <Windows.h>
- double a, b, c, d;
- int w=0;
- int i;
- char fam[256];
- int main() {
- SetConsoleCP(1251);
- SetConsoleOutputCP(1251);
- using namespace std;
- cout << "Введите ФИО покупателя: ";
- cin.getline(fam, 256, '\n');
- cout << "Введите сумму покупки: ";
- cin >> a;
- b = ((a / 100) * 6);
- c = a/10;
- d = a + b + c;
- system("pause");
- system("cls");
- cout << "\t" <<"\t"<<"\t"<< "НАКЛАДНАЯ" << "\n";
- for (i=57; i > w; w++)
- {
- cout << "_";
- };
- cout << endl<< endl;
- cout << " " << "ПОКУПАТЕЛЬ" << "\t" << "\t" << fam << endl;
- cout << " " << "Сумма заказа" << "\t" << "\t" << int(a * 100 + 0.5) / 100.0 << endl;
- cout << " " << "Налог" << "\t" << "\t" << "\t" << int(b * 100 + 0.5) / 100.0 << endl;
- cout << " " << "Транспортировка" << "\t" << int(c * 100 + 0.5) / 100.0 << endl;
- w = 0;
- for (i = 57; i > w; w++)
- {
- cout << "_";
- };
- cout << endl << endl;
- cout << " " << "Стоимость всего" << "\t" << int(d * 100 + 0.5) / 100.0 << endl;
- w = 0;
- for (i = 57; i > w; w++)
- {
- cout << "_";
- };
- cout << endl << endl;
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement