Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- setlocale(LC_ALL, "ru");
- int total, unit;
- cout << "Введите общее количество ткани: ";
- cin >> total;
- cout << "Введите количество ткани на единицу: ";
- cin >> unit;
- int count = 0;
- while (total >= unit) {
- total -= unit;
- count++;
- }
- cout << count << endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement