Quick actions

cmd+k|ctrl+k

Navigation

Languages

Самостоятельная работа 6 №3

Snippet info

Language

Cpp

Visibility

public

Author

dimonkoko1

Created

2018-10-16T05:41:11Z

Updated

2018-11-10T14:13:09Z

#include <iostream>
#include <ctime>
#include <cstdlib>

using namespace std;

int main() {
    ////////////////////////////////////////////// Задание №3 Вариант 80 ////////////////////////////////////////////////
    srand ( time(NULL) );
    int cars[29];
    
    for(int i = 0;i < 30;i++){
        cars[i] = rand() % 200 + 100;
        if(cars[i] > 200)
            cout << cars[i] << " л.с - мощность автомобиля превышает 200 л.с" << endl;
            else
                cout << cars[i]  << " л.с" << endl;
    }
    
    return 0;
}
INFO