By DePaul Dimadis
Choose your prefered Language: greek_flag uk_flag

A list of subjects for the exam period is to be prepared in a University Department.

For each lesson we know:

  1. Course code (integer in area [1-99])
  2. The semester to which he belongs (integer in area [1-9])
  3. The number of students and students who are going to take an examination (integer 1-999)

Write a C language program that will implement the following:

  1. It will import data into a table of integers with 3 * N in a plurality of positions, as described above. The known number N > 0 indicates the number of courses for which examinations will take place (i.e. there may not be any exams for some lessons). The introduction will take place using only random numbers - rand () - within the limits given for each triple of items. CAUTION!! Each course code should contain only one time on the board !!
  2. It will display a list of courses to be examined, every semester. The list will be ranked in ascending order of the semester and in ascending order of the course code within every six months, WITHOUT USING CLASSIFICATION PROCEDURES! At the end each semester should show the average of the people who are going to take the exam.

Numerial Example N=3:

15 2 45 49 7 190 74 8 77


SEMESTER: 2                             courses: 15                            average: 45

SEMESTER: 7                             courses: 49                            average: 190

SEMESTER: 8                             courses: 74                            average: 77