Minggu, 30 Oktober 2016

Program Delphi Daily Problem "PEMBELIAN TANAH"

procedure TTanah.Button1Click(Sender: TObject);
var

  m,o,n,s,l:real;
begin
  l:=strtofloat(edit1.Text);
  s:=500000;
  n:=2000000;
  o:=(l*n) + s;
  m:=(200*n) +s+((l-200)*s);
  if l<80 then edit2.Text:='Pembelian Minimal 80 Meter Persegi';
  if l>=80 then edit2.Text:=floattostr(o);
  if l>200 then edit2.Text:=floattostr(m);



end;

procedure TTanah.Button2Click(Sender: TObject);
begin
edit1.Text:=' ';
edit2.text:=' ';
end;

procedure TTanah.Button3Click(Sender: TObject);
begin
DailyProblems.Show;
Tanah.Hide;
end;

end.

0 komentar:

Posting Komentar