妈妈不见了# pets - 心有所宠
d*8
1 楼
Implement a program in C/C++ to serialize one or more link lists in the
file on disk which will let user perform following operations through
command line:
- Add a new list
- Display a given list
- Add a node to any given list
- Remove a node from a list
- Remove a list
- Exit program
Additional requirements:
- Provide optimal solution. Always read and update the file as and when
necessary, to avoid in-memory foot print.
- Nodes can be added in between any of the link lists, keep the link
lists sorted. There is no upper bound to the no. of nodes in a list.
- Reuse deleted node space from other linked list when adding new nodes
- Don't use stl list or third party libraries for serialization
Assumptions:
- All nodes are of same size for simplicity. Node in the list contains
integer data.
- Each list has an integer ID to identify it.
- Use single or double link list as appropriate (do not use STL)
- For simplicity leave the file fragmented when nodes or link list is
deleted
Submit completed project in running state. Submit the design write up
and test cases that you ran for the test.
file on disk which will let user perform following operations through
command line:
- Add a new list
- Display a given list
- Add a node to any given list
- Remove a node from a list
- Remove a list
- Exit program
Additional requirements:
- Provide optimal solution. Always read and update the file as and when
necessary, to avoid in-memory foot print.
- Nodes can be added in between any of the link lists, keep the link
lists sorted. There is no upper bound to the no. of nodes in a list.
- Reuse deleted node space from other linked list when adding new nodes
- Don't use stl list or third party libraries for serialization
Assumptions:
- All nodes are of same size for simplicity. Node in the list contains
integer data.
- Each list has an integer ID to identify it.
- Use single or double link list as appropriate (do not use STL)
- For simplicity leave the file fragmented when nodes or link list is
deleted
Submit completed project in running state. Submit the design write up
and test cases that you ran for the test.