Really simple Pascal

Assigning students to laboratory classes. Possibility of clashes ignored. 60 students enrolled on the course. You must assign each student to one of six different classes, taking into account the capacity of each class. Each student has four choices, none of which are guaranteed to be satisfied.

You need two files for the input to your program.

- A file called "[url removed, login to view]", contains details of the 60 students. Each student record has a surname of type string, a forename of type string, and their four choices of lab session, each option an integer, separated by spaces on a single line. A couple of records from the file might look like this:



1 3 4 2



4 6 5 2


which means that George Lewis' first choice of lab session is session number 1, then session number 3 etc.

- A file called "[url removed, login to view]". This contains details of the six lab classes to which the students must be assigned. Each lab class record has a number, of type integer, a day, of type string, a time, also of type string and a capacity, an integer. A couple of records:






Monday 3:30



which means that lab class one is at 1:30 on Mon. and can sit no more than 18 students.

Job is to read in the data, store them in appropriate data structures and then assign students to classes, ensuring that no class has more students than it can sit. You must then pring out a class at a time to the screen, detailing the lab class number, the day and time, an alphabetical list of the students assigned to that class, and a misery factor for that class. Your program should stop after printing each class' details so that the user can read the information provided. The misery factor of a class is the sum of the misery factor for each student in that class. Each student's misery factor is calculated:

- student assigned to 1st choice, misery factor 0

- student assigned to 2nd choice, misery factor 5

- 3rd choice, factor 10

- 4th choice, factor 15

- none of his choices misery factor 20


You may assume that the files are in the described format, that they exist and that there are no typing errors. You may assume that no class has a capacity of more than 15 students. If you make any other assumptions you must explain them in the form of comments at the top of your code.

## Deliverables

1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.

2) Installation package that will install the software (in ready-to-run condition) on the platform(s) specified in this bid request.

3) Exclusive and complete copyrights to all work purchased. (No GPL, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site).

## Platform

Delphi 6.0

Habilidades: Delphi, Engenharia, MySQL, PHP, Arquitetura de software, Teste de Software

Veja mais: type of data structures, out source printing, list of data structures, list in data structures, list data structures, integer factor, first lab, different data structures, data structures list, data structures explained, data structures code, typing screen, pascal, complete the four simple c++, chan, chan install, string integer, read option specified file, simple data structures, delphi string contains, delphi pascal, program pascal, data structures program, class printing, choice data structures

Acerca do Empregador:
( 3 comentários ) United Arab Emirates

ID do Projeto: #3004548

Concedido a:


See private message.

$7 USD em 2 dias
(12 Comentários)

5 freelancers estão ofertando em média $8 para esse trabalho


See private message.

$8.5 USD in 2 dias
(246 Comentários)

See private message.

$8.5 USD in 2 dias
(1 Comentário)

See private message.

$8.5 USD in 2 dias
(2 Comentários)

See private message.

$8.5 USD in 2 dias
(0 Comentários)