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

Заданы фамилии и рост учащихся 10-го класса. Вывести фамилию тех учащихся, рост которых меньше среднего роста по классу. Pascal

👇
Ответ:
pomorcevakata98
pomorcevakata98
24.05.2021

type

 Str = record

         fio: string;

         h: byte;

       end;

var

 base: array of Str;

 i,sum,n,err:integer;

 

begin

write('Число учеников: '); readln(n);

setlength(base,n);

sum:=0;

writeln('Введите фамилию и рост через "space": ');

for i:=0 to n-1 do

 begin

   write(i+1:4,'. ');

   readln(base[i].fio);

   

   val(copy(base[i].fio,

            pos(' ',base[i].fio)+1,  

            length(base[i].fio)-pos(' ',base[i].fio)),

       base[i].h,  

       err);

   delete(base[i].fio,

          pos(' ',base[i].fio),

          length(base[i].fio));

   sum:=sum+base[i].h;

 end;

writeln('Средний рост: ',sum/n:4:1);

for i:=0 to n-1 do

 if base[i].h<sum/n then

   writeln(base[i]);

end.

4,7(84 оценок)
Открыть все ответы
Ответ:
mirann2hsjb
mirann2hsjb
24.05.2021

A while loop is a type of loop that runs as long as a logical condition is True. When the logical condition becomes False, the loop stops running. The general form of a while loop in Python is below:

while <logical_condition>: <code>

The keyword while must be included, as well as a <logical_condition> which can be evaluated as True or False. The <code> after the while statement must be indented. Each line of code runs in the while loop needs to be indented the same number of spaces. (Many code editors, including Jupyter notebooks, auto-indent after a whilestatement) If you add indentation manually, four space spaces is the Python standard.

An example of a while loop is below:

In [1]:

i = 0 while i<4: print(i) i = i+1

The first line i=0 creates the variable i and assigns it the value 0. The next line declares the logical condition needed to keep the loop running. The statement i<4 is True or False depending on the variable i. Since i=0, the statement i<4 is Trueand the while loop starts to run. The code inside while the loop prints the value of i then increases iby 1. When i=4, the statement i<4 is False and the while loop ends.

4,5(98 оценок)
Ответ:
samwwww
samwwww
24.05.2021

1)Оглавле́ние — указатель заголовков издания, отражающий рубрикацию произведения и ускоряющий поиск частей издания.

2) Оглавление может быть:

I. Полным, т.е. включать все рубрики произведения;

II. Сокращенным, т.е. быть составленным из части заголовков (например, без заголовков в подбор с текстом или иных заголовков нижних ступеней рубрикации);

III. Расширенным, т.е. включать заголовки, которых в тексте нет или которые в тексте словесно не обозначены.

3) Оно используется для просмотра тем и в первую очередь раскрывает строение произведения.

Объяснение:

Отметьте как лучший

4,5(28 оценок)
Это интересно:
Новые ответы от MOGZ: Информатика
logo
Вход Регистрация
Что ты хочешь узнать?
Спроси Mozg
Открыть лучший ответ