I have the following code to do this, but how can I do it better? Right now I think it\'s better than nested loops, but it starts to get Perl-one-linerish when you have a ge
Using pendulum.period:
import pendulum start = pendulum.from_format('2020-05-01', 'YYYY-MM-DD', formatter='alternative') end = pendulum.from_format('2020-05-02', 'YYYY-MM-DD', formatter='alternative') period = pendulum.period(start, end) for dt in period: print(dt.to_date_string())