![](/images/backgrounds/286549/hp-sunsoft-pascal-4-0-users-manual-549395126x1.png)
6
The Pascal procedure, IntCA.p. Pascal passes the bounds pair.
The C main program,
IntCAMain.c
Examples of
Example 1:
procedure IntCA(var a: array [lb..ub: integer] of integer); begin
a[1] := 1;
a[2] := 2 end; { IntCA }
#include <stdio.h>
extern void IntCA(int [], int, int);
int main(void)
{
int k ;
static int s[] = { 0, 0, 0 };
IntCA (s, 0,
printf(" %d \n", s[k]);
}
The commands to compile and execute IntCA.p and IntCAMain.c with
hostname% pc
0
1
2
102 | Pascal 4.0 User’s Guide |