# -*- coding:utf-8 -*- import datetime __author__ = 'yangxin' def main(): begin = datetime.date(2017,9,10) end = datetime.date(2017,9,20) for i in range((end - begin).days+1): day = begin + datetime.timedelta(days=i) print str(day) if __name__ == '__main__': main()