Professional Documents
Culture Documents
PROGRAM CALCULATION;
{This program will calculate the total payment and total charge of a customer}
const
DiscRate=0.1;
TaxRate=0.15;
TreetrimPrice=13,000.00;
LawncarePrice=34,000.00;
FenceInstPrice=190,000.00;
LandscapePrice=400,000.00;
var
Count, Balance:integer;
Begin
DiscAmount:=0;
TaxAmount:=0;
GrandTotal:=0;
CustCharge:=0;
CustPayment:=0;
TreetrimCustCharge:=0;
LawncareCustCharge:=0;
FenceInstCustCharge:=0;
LandscapeCustCharge:=0;
TreeTrimpayment:=0;
FenceInsttpayment:=0;
Lawncarepayment:=0;
Landscapepayment:=0;
For Count:=1 to 2 Do
BEGIN
Writeln('Enter FName,LName');
Readln (FName,LName);
Writeln('Enter Servtype');
Readln (Servtype);
Writeln('Enter Servday');
Readln (Servday);
If (Servtype='Treetrim') then
begin
If (Servday='Monday')then
begin
end;
Readln (payment);
TreetrimCustCharge:=TreetrimCustCharge +CustCharge;
TreeTrimpayment:=TreeTrimpayment+ payment;
end
else
If (Servtype='Lawncare') then
begin
If (Servday='Monday')then
begin
end;
Readln (payment);
LawncareCustCharge:= LawncareCustCharge+CustCharge;
Lawncarepayment:=Lawncarepayment+ payment;
end
else
If (Servtype='FenceInst') then
begin
If (Servday='Monday')then
begin
end;
Readln (payment);
FenceInstCustCharge := TreeplantCustCharge+CustCharge;
FenceInstpayment:=Treeplantpayment+payment;
end;
else
If (Servtype='Landscape') then
begin
If (Servday='Monday')then
begin
end;
Readln (payment);
LandscapeCustCharge:=LandscapeCustCharge+ CustCharge;
Landscapepayment:=Landscapepayment+payment;
end;
end;
GrandTotalPayment:=
Treetrimpayment+Lawncarepayment+Landscapepayment+FenceInsttpayment;
HighestCharge:=TreetrimCustCharge
Else
HighestCharge:= LawncareCustCharge;
HighestCharge:= LawncareCustCharge
Else
HighestCharge:= LandscapeCustCharge;
Else
HighestCharge:= FenceInstCustCharge;
IF GrandTotalPayment>totalcharge THEN
else
IF GrandTotalPayment<totalcharge THEN
else
IF GrandTotalPayment=totalcharge THEN
end.