half_free completed?
It is completely untested so it will most probably need modifying later
to succeed in all the test cases.