12 | | 14 | 15 | 16 | 17 | 18 | 19 | | 20 |

© um.co.ua -

  1. .
  2. XXXVIII. ,
  3. - 2. (0 1).
  4. TP - ; - ; - ² 16 , .
  5. .

- , .

1. ³ .

2. : Button, Edit, Label.

3. 䳿:

22. 22

' Object Inspector ' / ' 䳿 ij
Form1 Properties Caption
Events OnCreate Text
Button1 Properties Caption
Events Onclick Text
Button2 Properties Caption
Events Onclick 䳿
Button3 Properties Caption
Events Onclick 䳿
Button4 Properties Caption
Events Onclick
Edit1 Properties Caption Text
Edit2 Properties Caption Text
Edit3 Properties Caption Text

4. ik, k, i: integer; s: string; a: array [1..15] of integer.

5. , .

procedureTform1.FormCreate (Sender: Tobject);

Begin

Edit1.Text: = '';

Edit2.Text: = '';

Edit3.Text: = '';

end;

procedureTform1.Button1Click (Sender: Tobject);

Begin

Edit1.Text: = '';

Edit2.Text: = '';

Edit3.Text: = '';

end;

procedureTform1.Button2Click (Sender: Tobject);

Begin

close;

end;

procedureTform1.Button3Click (Sender: Tobject);

Begin

k: = StrToInt (Edit2.Text);

Fori: = 1 to15 do

ifk = a [i] thenik: = i;

ifik = 0 thenEdit3.Text: = 'number ubsent'

elseEdit3.Text: = IntToStr (ik);

end;

procedureTform1.Button4Click (Sender: Tobject);

Begin

randomize;

s: = '';

Fori: = 1 to15 do

Begin

a [i]: = random (26);

s: = concat (s, IntToStr (a [i]), # 32);

end;

Edit1.Text: = s;

end;

end.

:

37



| 23