Sorry sir but I just made it complicated. Here is my problem now, how will I print the different passages without repeated because when I add a conditional statement inside the for loop the numbers are being repeated until all numbers are used.

Here is my updated code:

Code:
#include<stdio.h>  
#include <conio.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>

int getNextNum(){
  static int list[9];
  static int size=-1;
  if (size==-1){
    size=9;
    for(int i=0;i<size;i++){ 
      list[i]=i+1;
      }
    }
  if(size==0){
    return 0;
    }
  int index=rand()%size;
  int num=list[index];
  size--;
  list[index] = list[size];
  return num;
}


int main(){
  const time_t timer=time(NULL);
  printf("%s\n",ctime(&timer));
  
  srand( time(NULL));
  int z;
  for(int i=0;i<9;i++){
    z=getNextNum();
    switch(z){
      case 1:
        printf("Passage Number: %d\n",z);
        getche();
      case 2:
        printf("Passage Number: %d\n",z);
        getche();
      case 3:
        printf("Passage Number: %d\n",z);
        getche();
      case 4:
        printf("Passage Number: %d\n",z);
        getche();
      case 5:
        printf("Passage Number: %d\n",z);
        getche();
      case 6:
        printf("Passage Number: %d\n",z);
        getche();
      case 7:
        printf("Passage Number: %d\n",z);
        getche();
      case 8:
        printf("Passage Number: %d\n",z);
        getche();
      case 9:
        printf("Passage Number: %d\n",z);
        getche();
      }
    }
  getche();
}