please help I don't want the number in the first loop to be used in the second I can only do this for the first element only those not input in the first loop are used in the second loop.



void remove_list(FILE *file_ptr,char list[][70],int fnumber)
{
int num_files,file_num,loop,num,num1=0,line=5;
int file_num[25];

printf("\n\t\t\tnumber of file(s) to be removed:>");
scanf("%d",&num_files);

printf("enter file number(s):>");
for(loop=0;loop<num_files;loop++
scanf("%d",&file_num[loop]);

clrscr();

file_ptr=fopen("c:\\windows\\desktop\\test.txt","w ");

fseek(file_ptr,0,SEEK_SET);


for(num=0;num<fnumber;num++) /* fnumber=number of lines in file */
{
num1++;
if(num1==file_num[0])
continue;

fputs(list[num],file_ptr);

gotoxy(40-(strlen(list[num])/2),line++);
printf("%d: %s",num+1,list[num]);
}





fclose(file_ptr);


getch();
exit(0);
}


THANKS FOR THE HELP.