Reworked reverse in terms of foldLeft.