: Hi,
: I have ascii file, that has approximatelly 100 columns. I would like
: to read values in each column with loop in separate veriables. Can
: you advise me how to define vector variable which name would be
: changed in do loop. For example, values in column 1 would be read in
: variable col_1,...,values in column 100 would be read in variable
: col_100.
:
: Thanks
: Simon
:
Use an array. Define the array with the declaration
Var
col : array[1 .. 100] of real ; { or whatever type }
then read the file with a
for loop
for i := 1 to 100 do
read (f, col[i]) ;
readln (f) ;