What is a good algorithm for compacting records in a blocked file?

前端 未结 4 1182
长情又很酷
长情又很酷 2021-01-20 05:31

Suppose you have a large file made up of a bunch of fixed size blocks. Each of these blocks contains some number of variable sized records. Each record must fit completely w

4条回答
  •  渐次进展
    2021-01-20 05:43

    Here's an algorithm you might be able to leverage, albeit your records within fixed size blocks might require a little bit more work.

    Heap Defragmentation in Bounded Time

提交回复
热议问题