М
Молодежь
К
Компьютеры-и-электроника
Д
Дом-и-сад
С
Стиль-и-уход-за-собой
П
Праздники-и-традиции
Т
Транспорт
П
Путешествия
С
Семейная-жизнь
Ф
Философия-и-религия
Б
Без категории
М
Мир-работы
Х
Хобби-и-рукоделие
И
Искусство-и-развлечения
В
Взаимоотношения
З
Здоровье
К
Кулинария-и-гостеприимство
Ф
Финансы-и-бизнес
П
Питомцы-и-животные
О
Образование
О
Образование-и-коммуникации
Lenechka20
Lenechka20
09.05.2020 10:22 •  Информатика

вставь пропущенное слово.
-это несколько элементов
с общими именем и нумерацией.

👇
Ответ:
lenok1067
lenok1067
09.05.2020

Массив

Объяснение:

4,5(50 оценок)
Ответ:
Bon2000
Bon2000
09.05.2020

В информатике это Массив

4,6(71 оценок)
Открыть все ответы
Ответ:
Kotliarrostislav
Kotliarrostislav
09.05.2020

Во-первых в начале НЕ сin << sys, а сin >> s;

Во-вторых ты объявил/а все переменные в первом ифе, а значит в других функциях они уже не видны, поэтому стоит их объявить глобально

В-третьих переменная g не используется, поэтому можно ее и не объявлять

Вот код:

#include <iostream>

#include <cmath>

using namespace std;

int main() {

   int sys;

   float a, b, c, d, e, sum, mid, pi=3.14, r;

   cout << "if you would midle write-1, if place of circle-2" << endl;

   cin >> sys;

   if(sys == 1) {

       cout << "input first midle" << endl;

       cin >> a;

       cout << "inpur second midle" << endl;

       cin >> b;

       cout << "input third midle" << endl;

       cin >> c;

       cout << "input thord midle" << endl;

       cin >> d;

       cout << "input fived midle" << endl;

       cin >> e;

       sum = a + b + c + d + e;

       mid = sum / 5;

       cout << "your midle: ";

       cout << mid;

   }

   else{

       if(sys == 2) {

           cout << "this is the circle area formula S=pi*r^2" << endl;

           cout << "input radius(r)" << endl;

           cin >> r;

           cout << pi * r * r;

       }

   }

   return 0;

}

4,8(77 оценок)
Ответ:
умница603
умница603
09.05.2020

С++20

#include <iostream>#include <vector>class Point {public:    int x, y;    Point() = default;    Point(const Point &) = default;    Point(int _x, int _y) : x(_x), y(_y) {}    Point operator + (const Point& p) const {        return Point {x + p.x, y + p.y};    }    Point operator - (const Point& p) const {        return Point {x - p.x, y - p.y};    }    std::vector<Point> operator & (const Point& p) const {        return std::vector<Point> {                Point {x + p.x, y + p.y},                Point {x - p.x, y + p.y},                Point {x + p.x, y - p.y},                Point {x - p.x, y - p.y},                Point {x + p.y, y + p.x},                Point {x - p.y, y + p.x},                Point {x + p.y, y - p.x},                Point {x - p.y, y - p.x},        };    }    static Point max (const Point& p1, const Point& p2) {        return Point {std::max(p1.x, p2.x), std::max(p1.y, p2.y)};    }    static Point min (const Point& p1, const Point& p2) {        return Point {std::min(p1.x, p2.x), std::min(p1.y, p2.y)};    }    [[nodiscard]] int distance_to_by_ch (const Point & p) const {        return std::max(std::abs(p.x - x), std::abs(p.y - y));    }    [[nodiscard]] int distance_to_by_m (const Point & p) const {        return std::abs(p.x - x) + std::abs(p.y - y);    }    friend std::ostream &operator << (std::ostream &os, Point const &p) {        return os << "(" << p.x << ";" << p.y << ")";    }    Point & operator = (const Point &) = default;    bool operator == (const Point & p) const {        return x == p.x && y == p.y;    }};class Horse {public:    const Point p;    explicit Horse (const Point position) : p(position) { }    [[nodiscard]] bool can_I_kill_this_guy (const Point & m) const {        auto field = p & Point{2, 3};        return std::find(field.begin(), field.end(), m) != field.end();    }};std::istream &to_number(std::istream &stream) {    char ch;    do {        ch = stream.get();    }    while (!isalpha(ch));    if (isupper(ch)) ch -= 16; else ch -= 48;    stream.putback(ch);    return stream;}int main () {    Point horse_p{}, stranger_p{};    std::cin >> horse_p.x >> to_number >> horse_p.y;    std::cin >> stranger_p.x >> to_number >> stranger_p.y;    Horse jack(horse_p);    std::cout << "I am a Horse placed on " << jack.p << ". "              << "Can I kill those guy on " << stranger_p << "? "              << "-> " << std::boolalpha << jack.can_I_kill_this_guy(stranger_p); }
Поле шахматной доски определяется парой – буква и цифра. Буква (a … h) означает горизонталь при счет
Поле шахматной доски определяется парой – буква и цифра. Буква (a … h) означает горизонталь при счет
Поле шахматной доски определяется парой – буква и цифра. Буква (a … h) означает горизонталь при счет
4,6(3 оценок)
Это интересно:
Новые ответы от MOGZ: Информатика
logo
Вход Регистрация
Что ты хочешь узнать?
Спроси Mozg
Открыть лучший ответ