eliseygrid53
06.05.2023 03:30

3. Создать форму-счет в виде таблицы для одного наименования товара. В поле Название товара сформировать список с перечнем наименований товаров (арматура, кирпич, бетонная балка, кирпич, черепица). В поле Сумма обеспечить возможность расчета стоимости товара с учетом оптовой скидки Если приобретено менее 50 единиц товара-скидка не предоставится; Если приобретено от 50 до 100 единиц товара размере 2% от стоимости; скидка в Если приобретено более 100 единиц товара скидка в размере 3% от стоимости. Для защиты постоянной информации от редактирования необходимо защитить электронную форму. Для этого: на вкладкци Разработчик в группе Защитить нажать кнопку Защитить документ и выбрать команду ограничить форматирование и форматирование и редактирование выбрать параметр Ввод данных в поля форм и нажать кнопку Да, включить защиту области ограничить Ограничения редактирование задач редактирование, разделе


3. Создать форму-счет в виде таблицы для одного наименования товара. В поле Название товара сформир

Нажмите на рекламу ниже и сразу увидите ответ
Популярные вопросы:
Ответ:
49583
27.12.2022 21:23
Romanf romanf отличник 2013-01-10t16: 13: 22+00: 00 1. подумать над алгоритмом 2. вот сам алгоритм: а. спросить у пользователя значения б. расчитать ответ в. выдать ответ на экран 3. написать код в паскале 4. исправить ошибки компиляции 5. протестировать, вводить разные числа 6. обнаружила, что если вводить числа наугад ответ получается отрицательным иногда 7. вставить код проверки введенных пользователем значений 8. убрать ошибки компиляции 9. протестировать 10. готово а вот и сама программа: program aerobus; uses crt; const totalplace = 160; var businessplaces, economyplaces: integer; businessprice, economyprice: real; totalcharge: real; a,b: integer; correctinput: boolean; begin clrscr; businessplaces: =totalplace div 4; economyplaces: = totalplace - businessplaces; writeln('business places count: ', businessplaces); writeln('economy places count: ', economyplaces); correctinput: =false; while not correctinput do begin write('please input business class ticket price: '); readln(businessprice); if(businessprice> 0) then begin correctinput: =true; end else begin writeln('the price should be a positive number, please try again'); end; end; economyprice: =businessprice/2; writeln('economy ticket price is: ', economyprice: 0: 2); correctinput: =false; while not correctinput do begin write('how many business tickets are left? : '); readln(a); if(a> =0) and (a< =businessplaces)then correctinput: =true; if(a< 0) then begin writeln('please input a positive number or 0, please try again'); end; if(a> businessplaces) then begin writeln('please input a number which is less or equal to the tolal business place count, please try again'); end; end; correctinput: =false; while not correctinput do begin write('how many economy tickets are left? : '); readln(b); if(b> =0) and (b< =economyplaces)then correctinput: =true; if(b< 0) then begin writeln('please input a positive number or 0, please try again'); end; if(b> economyplaces) then begin writeln('please input a number which is less or equal to the tolal economy place count, please try again'); end; end; totalcharge: =(businessplaces-a)*businessprice; totalcharge: =totalcharge+(economyplaces-b)*economyprice; writeln('the total charge is: ', totalcharge: 0: 2); writeln; writeln('press enter to exit'); readln; end.
0,0(0 оценок)
Ответ:
polinasenchenk
17.09.2022 15:22

//Задача 3

#include <iostream>

#include <stdio.h>

using namespace std;

string SubString(string str, int startIndex, int endIndex)

{

   string output = "";

   for (int i = startIndex; i < endIndex; i++)

       output += str[i];

   return output;

}

string ToString(int num)

{

   string output = "";

   char symbol = 0;

   int tmp = num;

   while(num != 0)

   {

       tmp = num % 10;

       num /= 10;

       symbol = (char)(tmp + 48);

       output = symbol + output;

   }

   return output;

}

int IndexOf(string str, char symbol)

{

   int index = -1;

   for (int i = 0; i < str.length(); i++)

   {

       if (str[i] == symbol)

       {

           index = i;

           break;

       }

   }

   return index;

}

bool Contains(string text, char symbol)

{

   for (int i = 0; i < text.length(); i++)

   {

       if (text[i] == symbol)

           return true;

   }

   return false;

}

bool IsRepeat(string values, string num)

{

   string tmp = "";

   while (IndexOf(values, ' ') != -1)

   {

       values = SubString(values, IndexOf(values, ' ') + 1, values.length() + 1);

       tmp = SubString(values, 0, IndexOf(values, ' '));

       if (tmp == num)

           return true;

   }

   return false;

}

int main()

{

   const int arrSize = 10;

   int arr[arrSize] = { 10, 22, 10, 76, 44, 22, 22, 12, 9, 76};

   string values = "";

   bool couples = false;

   for (int i = 0; i < arrSize; i++)

   {

       string str = ToString(arr[i]);

       for (int j = i + 1; j < arrSize; j++)

       {

           if (arr[i] == arr[j] && !IsRepeat(values, ToString(arr[j])))

           {

               str += " " + ToString(arr[j]);

               values += " " + ToString(arr[j]);

           }

       }

       if (Contains(str, ' '))

       {

           couples = true;

           cout << "Couple: " << str << endl;

       }

   }

   if (!couples)

       cout << "Couple not detected!" << endl;

   return 0;

}

--------------------------------------------------------------------------

//Задача 5

#include <iostream>

using namespace std;

string ToLower(string text)

{

   string output = "";

   for (int i = 0; i < text.length(); i++)

       output += tolower(text[i]);

   return output;

}

int main()

{

   string str1 = "";

   string str2 = "";

   cout << "Enter first string: ";

   getline(cin, str1);

   cout << "Enter second string: ";

   getline(cin, str2);

   if (ToLower(str1) == ToLower(str2))

       cout << endl << "Strings are equal" << endl;

   else

       cout << endl << "Strings are not equal" << endl;

   return 0;

}


Написать программу на c++ выделены
0,0(0 оценок)
Полный доступ
Позволит учиться лучше и быстрее. Неограниченный доступ к базе и ответам от экспертов и ai-bota Оформи подписку
logo
Начни делиться знаниями
Вход Регистрация
Что ты хочешь узнать?
Спроси ai-бота