Fixed heapsort(), and removed array_append() functions.