Question: Best way to index Variables

Hi, i have a rather basic question. Both code pieces do the same:

restart:
 for i from 1 to 5 do  a[i]:=i;  end do;

a[3];

3

restart:
 for i from 1 to 5 do  a(i):=i;  end do;

a(3);

3

 

In which case should  i use round brackets and when square brackets for indexing ?

Does it matter ?

 

Thomas

Please Wait...