Yang paling dekat di antara

int num;
  
  int x;
  
  printf("Enter the total number of our men: ");
  scanf("%d", &num);
  
  int men[num];
  int n,n1;
  
  for(x=1; x<=num; x++){
  	
  
  printf("Men #%d: ", x);
  scanf("%d", &men[x]);
  
  //if(x>=num+1)
  
  }
  
  printf("Enemy #1: ");
  scanf("%d",&n);
  
  printf("Enemy #2: ");
  scanf("%d",&n1);  
  
   printf("\nMen Cornered:\n");
  
  for(x=1; x<=num; x++){
  	
  if(men[x]<=n1 && men[x]>=n){
    
   
    printf("%d ",men[x]);
  
  }}
Amauna