cleaned heap code
cleaned heap