I just wanted to know that can we implement Linked List in File handling i.e. Can we store the data inside a file in the form of linked list or any other data structure??
Thanks
I just wanted to know that can we implement Linked List in File handling i.e. Can we store the data inside a file in the form of linked list or any other data structure??
Thanks
Well, my assignment this semester is going to involve file io and linked lists, so I would guess so. I don't know how at the moment though... I'll find out soonish I guess.
O_o
Memory: For our purposes, memory is a contiguous block of bits available for any purposes that we wish to put it.
Files: For our purposes, memory is a contiguous block of bits available for any purposes that we wish to put it.
The only differences, again for the purposes of the discussion, is the speed and size.
Any data structure you can imagine being implemented with memory can be adapted for use with files.
Some data structures are just not suitable for use with files. It would not be difficult to implement a linked list using a file, or multiple files, as storage. Such a beast may just not show reasonable performance for any given usage. There are, however, many data structures designed specifically for use with files as storage; many such data structures are unsuitable, or just silly, for use with memory as storage.
So, the questions become, what are wanting to store, how are you needing to access it, and how is the data mutated. Answer those questions and you'll know if a linked list with a file for storage is likely to be a good place to start.
Soma