how to simulate file space allocation with c++

i want to write a c++ code that due the structure of file space allocation,Simulates file system with 2*n array.Each column represents a sector,The first row is for storing files And second row holds the address of the next sector (Number of columns).and With each click on keyboard Create a file with random size and automatically find Appropriate sectors by using disk allocation method (or index allocation)...Also File names should be asked from user...and we should have file table Where the starting address of each sector,file extention and file size is given..
Topic archived. No new replies allowed.