MAINT: simplifying calls to range, thanks @ElDeveloper