program tak_luxurious_house;
uses WINcrt;
var na : longint;
pjk : real;
begin
clrscr;
writeln('Input price of house asset ');
write('asset = $');read(na);
if na<30000 then pjk:=800;
if na<=50000 then pjk:=800+0.01*(na*10000-30000);
if na<=80000 then pjk:=800+0.012*(na*10000-30000);
if na<=120000 then pjk:=800+0.014*(na*10000-30000);
if na>120000 then pjk:=800+0.015*(na*10000-30000);
writeln;
writeln('price of house asset is: $ ',na);
writeln('tak of house asset is : $ ',pjk:0:2);
readln;
end.
if we run the statement,we are get output like this :
No comments:
Post a Comment