]>
Commit | Line | Data |
---|---|---|
cc78dedd | 1 | #include <stdio.h> |
2 | ||
3 | static void init_arr(/*@out@*/ float[],/*@out@*/ long int*); | |
4 | ||
5 | int main(void) | |
6 | { | |
7 | int j; | |
8 | long i; | |
9 | float arr[2]; | |
10 | ||
11 | init_arr(arr,&j); | |
12 | for( i=0; i < j; i++ ) { | |
13 | printf("%ld %d: %.6e\n",i,j,arr[i]); | |
14 | } | |
15 | return(0); | |
16 | } | |
17 | ||
18 | void init_arr(float arr[], | |
19 | long int *j) | |
20 | { | |
21 | long i; | |
22 | ||
23 | *j = 2L; | |
24 | for( i=0; i < 2L; i++ ) { | |
25 | arr[i] = (float)(i+1); | |
26 | } | |
27 | } |