Проект. Реєстраційна форма для ЗНО

Програмний код:

procedure TForm1.Button1Click(Sender: TObject);
var m,sh,p1,p2,p3:string;
begin
  if ComboBox1.ItemIndex =0 then m:='Вінниця';
  if ComboBox1.ItemIndex =1 then m:='Чернівці';
  if ComboBox1.ItemIndex =2 then m:='Хмельницький';
  label1.visible:=true;
  edit1.Text:=m;
  if ComboBox2.ItemIndex =0 then sh:='СЗШ №8';
  if ComboBox2.ItemIndex =1 then sh:='СЗШ №9';
  if ComboBox2.ItemIndex =2 then sh:='СЗШ №12';
  edit2.Text:=sh;
  p1:='Українська мова';
  if CheckGroup1.Checked[1] then p2:='Історія України' else
  if CheckGroup1.Checked[2] then p2:='Математика';
  edit3.Text:=p1+' '+p2;
  if CheckGroup1.Checked[3] then p3:='Фізика';
  if CheckGroup1.Checked[4] then p3:='Хімія';
  if CheckGroup1.Checked[5] then  p3:='Географія';
  if CheckGroup1.Checked[6] then  p3:='Біологія';
  if CheckGroup1.Checked[7] then  p3:='Англійська мова';
  Edit3.Text:='Предмети: '+p1+' '+p2+' '+p3;
  if RadioGroup1.ItemIndex =0 then Edit4.Text:='так';
  if RadioGroup1.ItemIndex =1 then Edit4.Text:='ні';
end;   

Завдання практичної роботи №12. Розрахунок оплати за електроенергію

procedure TForm1.Button1Click(Sender: TObject);
var k:integer;
  s:real;
begin
 k:=StrToInt(Edit1.Text);
 if ComboBox1.ItemIndex=0 then k:=k-30;
 if k<=100 then s:=k*57.0;
 if (k>100) and (k<=600) then s:=k*99.0;
 if k>600 then s:=k*156.0;
 Edit2.text:=FloatToStr(s);
end;