ГлавнаяСборникиТурнирыРазделыФорумыУчастникиПечатьПомощьО системе

Разделы > Поиск > задача:


51057 - Number of students

Гость
• Вопросы к жюри (2)

Задачи раздела

• 50980 - The smallest rectangle
• 50860 - Number of Student Certificates
• 50832 - Rock Paper Scissors Lizard ...
• 50834 - The train which leaves the f...
• 51078 - Max trade
• 51056 - Welcome Picnic
• 51055 - The competition
• 51077 - Grades Histogram
• 51057 - Number of students
• 51046 - The biggest number
• 50535 - Image Compression
• 50450 - Last Appereance of a Number
• 50457 - The Number of Winners
• 50453 - The Cubic Difference
• 50451 - Processing Cost
• 50459 - The Biggest Digit
• 50538 - Sum of kth Diagonal

Обратная связь

Если у вас есть предложения или пожелания по работе Contester, посетите форум сайта www.contester.ru.

Лимит времени 2000/4000/4000/4000 мс. Лимит памяти 65000/65000/65000/65000 Кб.
Question by Ibrahim Mesecan.

Q4

Question: One of your professors needs assistance. He wants to write a program to calculate the average of students and to count the number of students whose average is above (<) a given grade (k). The professor calculates the averages as follows, 65 percent of the highest grade and 35 percent of the lowest grade. Every student has at most 10 grades where the grades are integers between 30 and 100. The max grade is calculated as regular: max of the given grades. On the other hand, to calculate the min regularly, the student must have at least 6 grades. If a student has less than 6 grades, his min is taken as 0.

Input specification: You will be given two integers in the beginning: The number of students (n) and the grade (k) above which you are going to count the number of students. The following n lines will have at most 10 integers (integers between 30 and 100) separated by a comma where the last grade is followed by a semicolon. n is an integer 1 and 10,000 and k is between 1 and 100.

Output specification: Show one integer.

Sample Input
6 75
67,63,98,93,98,36,60;
51,91,96,44,54,40,80,49,61;
79,62,89,96,37,53,43,71,74;
44,60,41,35;
85,71,35,45,89,52,40,50,48,57;
46,61,71,48,54,31,92;
Sample Output
3

Explanation: The first student has seven grades where his min is 36 and his max is 98. Thus his average will be 76.3. The table on the right gives the information about average calculation for each student.



Для отправки решений необходимо выполнить вход.

www.contester.ru