Gives me the error on the line :while costumepmt <> 7777 AND revname <> 'qqqq' do, I really don't know what to do, please help, thanks in advance!
Program revelers_info;
uses wincrt;
var revnames, busybodies, summerbodies, readybodies, winnerbodies, goldenbodies :Array[1..7] of string;
costumepmt, busybodiescost, summerbodiescost, readybodiescost, winnerbodiescost, goldenbodiescost:Array[1..7] of real;
busybodiestot, summerbodiestot, readybodiestot, winnerbodiestot, goldenbodiestot, amount:real;
revname:string;
i, a, option, busybodiescnt, summerbodiescnt, readybodiescnt, winnerbodiescnt, goldenbodiescnt :integer;
Begin
a:= 1 ;
i:= 1;
busybodiescnt:=0;
summerbodiescnt:=0;
readybodiescnt:=0;
winnerbodiescnt:=0;
goldenbodiescnt:=0;
busybodiestot:=0;
summerbodiestot:=0;
readybodiestot:=0;
winnerbodiestot:=0;
goldenbodiestot:=0;
writeln('------------------------------------------------------------------------');
writeln('Welcome to THE MAIN EVENT Carnival Band Software!');
writeln;
Repeat
writeln('Please enter qqqq for name and 7777 for cost to terminate the process.');
writeln('Please choose one of the following options by entering the number of the option: ');
writeln('1. Add Information');
writeln('2. View Information');
writeln('3. Exit');
writeln;
readln(option);
If option = 1 then
Begin
writeln('Please enter a revelers name and then press the enter key.');
read(revname);
writeln('Please enter the amount paid by the Reveler for his or her costume.');
read(costumepmt[i]);
while costumepmt <> 7777 AND revname <> 'qqqq' do
Begin
revnames[i]:=revname;
If costumepmt = 144 then
Begin
busybodiescost[i]:= costumepmt[i];
busybodiestot:= busybodiestot+busybodiescost[i];
busybodies[i]:= revnames[i];
busybodiescnt:=busybodiescnt+1;
End;
If costumepmt = 204 then
Begin
summerbodiescost[i]:= costumepmt[i];
summerbodiestot:= summerbodiestot+summerbodiescost[i];
summerbodies[i]:= revnames[i];
summerbodiescnt:=summerbodiescnt+1;
End;
If costumepmt = 264 then
Begin
readybodiescost[i]:= costumepmt[i];
readybodiestot:= readybodiestot+readybodiescost[i];
readybodies[i]:= revnames[i];
readybodiescnt:=readybodiescnt+1;
End;
If costumepmt = 334 then
Begin
winnerbodiescost[i]:= costumepmt[i];
winnerbodiestot:= winnerbodiestot+winnerbodiescost[i];
winnerbodies[i]:= revnames[i];
winnerbodiescnt:=winnerbodiescnt+1;
End;
If costumepmt = 409 then
Begin
goldenbodiescost[i]:= costumepmt[i];
goldenbodiestot:= goldenbodiestot+goldenbodiescost[i];
goldenbodies[i]:= revnames[i];
goldenbodiescnt:=goldenbodiescnt+1;
End;
i:=i+1;
writeln('Please enter a Revelers name and then press the enter key.');
readln(revname);
writeln('Please enter the amount Paid by the Reveler mentioned.');
readln(costumepmt[i]);
End;
writeln;
End;
If option = 2 then
Begin
writeln('Busy Bodies Revelers names: ');
For a:= 1 to i do
Begin
writeln(busybodies[i]);
End;
writeln('The total cost calculated for the Busy Bodies Revelers is ' ,busybodiestot,'.');
writeln('The total number of Revelers in the Busy Bodies section is ' ,busybodiescnt,'.');
writeln('Summer Bodies Revelers names: ');
For a:= 1 to i do
Begin
writeln(summerbodies[i]);
End;
writeln('The total cost calculated for the Summer Bodies Revelers is ' ,summerbodiestot,'.');
writeln('The total number of Revelers in the Summer Bodies section is ' ,summerbodiescnt,'.');
writeln('Ready Bodies Revelers names: ');
For a:= 1 to i do
Begin
writeln(readybodies[i]);
End;
writeln('The total cost calculated for the Ready Bodies Revelers is ' ,readybodiestot,'.');
writeln('The total number of Revelers in the Ready Bodies section is ' ,readybodiescnt,'.');
writeln('Winner Bodies Revelers names: ');
For a:= 1 to i do
Begin
writeln(winnerbodies[i]);
End;
writeln('The total cost calculated for the Winner Bodies Revelers is ' ,winnerbodiestot,'.');
writeln('The total number of Revelers in the Winner Bodies section is ' ,winnerbodiescnt,'.');
writeln('Golden Bodies Revelers names: ');
For a:= 1 to i do
Begin
writeln(goldenbodies[i]);
End;
writeln('The total cost calculated for the Golden Bodies Revelers is ' ,goldenbodiestot,'.');
writeln('The total number of Revelers in the Golden Bodies section is ' ,goldenbodiescnt,'.');
End;
Until option = 3;
writeln('Thanks for stopping at THE MAIN EVENT Carnival Band Information boothe, now Get Ready For The ROOOOOAAAADDD!!!');
End.
Delano_1 0 Newbie Poster
SalmiSoft 102 Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.