indexed.c - #include<stdio.h>#include<conio.h>#include<stdlib.h> void main int f[50 index[50,i n st len j c k ind,count=0 clrscr for(i=0;i<50;i f[i]=0

indexed.c -...

This preview shows page 1 out of 1 page.

#include<stdio.h> #include<conio.h> #include<stdlib.h> void main() { int f[50], index[50],i, n, st, len, j, c, k, ind,count=0; clrscr(); for(i=0;i<50;i++) f[i]=0; x:printf("Enter the index block: "); scanf("%d",&ind); if(f[ind]!=1) { printf("Enter no of blocks needed and no of files for the index %d on the disk : \n", ind); scanf("%d",&n); } else { printf("%d index is already allocated \n",ind); goto x; } y: count=0; for(i=0;i<n;i++) { scanf("%d", &index[i]); if(f[index[i]]==0)

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture