demo_datetime_strftime.py:
import datetime x = datetime.datetime(2018, 6, 1) print(x.strftime("%B"))
➜ begtut>python demo_datetime_strftime.py
June