program Test;var myArray: array[1..200] of integer; i: integer;Procedure Test (Input: Array Of Integer);begin writeln('200th Entity is: ', Input[200]); writeln('200th Entity is: ', myArray[200]);end;begin for i:=1 to 9 do myArray[i] := 10 + i; test(myArray); readln;end.
The array of integers, 'myArray', is being inserted into the procedure 'Test', and no modifications are done, I'm simply reading the final integer in the array.
Procedure Test (Input: Array Of Integer);
type TMyArray = array[1..200] of integer;var myArray: TMyArray;...Procedure Test (Input: TMyArray);
Code: [Select]Procedure Test (Input: Array Of Integer);The parameter looks like a dynamic array but it is not. It is called "open array parameter" or something. You should not use it here.Instead you should define an own type a use it as function parameter.
Code: [Select]type TMyArray = array[1..200] of integer;var myArray: TMyArray;...Procedure Test (Input: TMyArray);Your original code is confusing. It defines 1..200, initializes 1..9 and accesses at 3000.Juha