#include #include #include #include #include int a[20], b[20], c[20], r[20], max[5000] ; /* max is an array which stores all input from the input file */ int main(argc,argv) int argc; char **argv; { int n = 0; int flag = 0; double min, shade[20] ; int k, l, g, m, x1, o, p, temp; FILE *fp; int flag1, flag2; int q = 0; m =0; fp = fopen("test1","rt"); if(fp==NULL) { printf("cannot open file"); exit(0); } /* get all the values from the input file into the array max */ while(!feof(fp)) fscanf(fp,"%d", &max[n++]); min = max[0]; for (i = 0; i < n; i++) {