Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Program Winning_Candidate;
{This program will determine the winning candidate for a specific
constituency}
VAR Tot_votes : array [03) of integer;
Cand_names: These are being declared and stored in array [0..3]
of string; memory for later use by the program.
i, Index, TempVotes:
Integer;
BEGIN
for This is a loop which enables the program to run 4 times i:=0
to 3 do;
BEGIN
ReadLn(Cand_names[i]);
ReadLn(Tot_votes[i]);
Index:=0;
TempVotes:=Tot_votes[Index];
for i:=1 to 3 do
if Tot_votes[i]>TempVotes then
BEGIN
Index:=i;
TempVotes:=Tot_votes[i];
Pseudocode
PROGRAM WINNING_CANDIDATE_FOR_GECOM
Description:{This program will determine the winning candidate for a specific
constituency}
Cand_name: String;
Tot_votes,initial_votes,v: Integer;
BEGIN
Initial_votes:=0;
FOR v = 1 to 4 DO;
READ (Cand_name);
PRINT (Can you please enter the total votes that the candidate received);
READ (Tot_votes);
ENDFOR;
ENDIF;
Documentation
The above program was written by to assist the
TRINBARGAM Election commission in order to determine a winner, fair fully
for a specific region that is present in Guyana.
SYSTEM REQUIREMENTS FOR THE ABOVE PROGRAM
General requirements includes:
Windows XP, Windows 2000 Professional sp3, Windows Vista, Windows
8.
Minimum of 64MB ram
2MB hard disk space
Screen resolution of 800 x 600 or higher
Pentium 333MHz or higher
PROGRAM INSTALLATION:
Insert CD-ROM in CD drive
Run setup exe from autorun.
NB: This installation could be done over a network as well.
PROGRAM UNINSTALLATION:
Open control panel.
Click on install/uninstall programs.
Then double click on program name.
After the installation progress, open extension from desktop and enter
information required by program (i.e. names of candidate and their total
votes)
During the writing progress of this program, errors couldve been made by
the programmer, end-user can correct these error (if any present) by using
Ezy Pascal and recompiling the program to identify the areas which contains
the error (s) or by correcting it manually, that is the use of trace tables.
Content Page
Introduction
Acknowledgement
Program Definition
Pseudocode
Algorithm
Program Documentation
Conclusion