increased performance of enumFromTo using tailrecursion