add compare loop and append sorted values
kill tab/space bugs
infinite loop bug now exists...ooops