Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- void main()
- {
- char filename[20];
- int startblock,blocksize,i,fb;
- int freeblock[20];
- printf("\n enter the file name");
- scanf("%s",filename);
- printf("\n enter the starting block and blocksize: ");
- scanf("%d%d",&startblock,&blocksize);
- printf("\n enter the number free blocks");
- scanf("%d",&fb);
- printf("\n
- for(i=0;i<fb;i++)
- {
- scanf("%d",&freeblock[i]);
- }
- printf("\n\n the file name is : %s",filename );
- printf("\nthe linked list file allocation is\n ");
- printf("%d->",startblock);
- for(i=0;i<blocksize-1;i++)
- {
- printf("%d->",freeblock[i]);
- }
- }
Add Comment
Please, Sign In to add comment