我正在尝试将文件指针数组传递给函数(不确定术语)。谁能解释一下发送“in[2]”的正确方法吗?谢谢你。
#include<stdio.h>
#include<stdlib.h>
void openfiles (FILE **in[], FILE **out)
{
*in[0] = fopen("in0", "r");
*in[1] = fopen("in1", "r");
*out = fopen("out", "w");
}
void main()
{
FILE *in[2], *out;
openfiles (&in, &out);
fprintf(out, "Testing...");
exit(0);
}