Вкоде где-то ошибка.тест. var form2: tform2; ball: integer; type answers=array[1..15,0..3]of byte; const otv: answers=(0,1,0,,0,,0,0,,0,1,0,,0,1,,0,1,,0,1,,,0,,0,1,,0,,0,1,,0,1,,1,,0,1,0)); implementation {$r *.dfm} procedure tform2.btn1click(sender: tobject); begin ball: =otv[1,rg1.itemindex]+ otv[2,rg2.itemindex]+ otv[3,rg3.itemindex]+ otv[4,rg4.itemindex]+ otv[5,rg5.itemindex]+ otv[6,rg6.itemindex]+ otv[7,rg7.itemindex]+ otv[8,rg8.itemindex]+ otv[9,rg9.itemindex]+ otv[10,rg10.itemindex]+ otv[11,rg11.itemindex]+ otv[12,rg12.itemindex]+ otv[13,rg13.itemindex]+ otv[14,rg14.itemindex]+ otv[15,rg15.itemindex]+ lbl1.caption: ='правильно ответил на'+inttostr(ball)+'из 15-ти вопросов'; if ball=15 then lbl2.caption: ='молодец: )' else if (ball=5) or (ball=9) then lbl2.caption: ='не всегда был внимательный' else lbl2.caption: =' плохо: (' end; end.
115
441
Ответы на вопрос:
Вмассива констант не хватает начальной скобки const otv: answers=(0,1,0,0), должно быть const otv: answers=((0,1,0,0),в круглых скобках должно быть по 4 значения, а у вас и по 3 и по 2 и даже 5( 4зн ), (4 зн ), . . (4 зн. ));
Популярно: Информатика
-
Kally200727.03.2020 13:42
-
Милка111111111111724.07.2021 07:09
-
Торт12327.12.2020 16:58
-
Викитирон09.02.2023 12:05
-
Nastya2oo325.04.2023 03:03
-
181101s28.07.2022 01:26
-
guzel3221110.12.2021 10:13
-
BorzikovaLiza522.06.2020 19:17
-
nastjaivanova2013.02.2022 13:33
-
ogannisyan200106.10.2020 21:23