REF: de-duplicate month/year rolling in libperiod (#34648)
REF: de-duplicate month/year rolling in libperiod (#34648)

* REF: implement helpers to de-duplicate year/month rolling

* move func to better location
jorisvandenbossche/pandas,rs2/pandas,gfyoung/pandas,pandas-dev/pandas,rs2/pandas,dsm054/pandas,gfyoung/pandas,gfyoung/pandas,datapythonista/pandas,dsm054/pandas,jreback/pandas,jorisvandenbossche/pandas,gfyoung/pandas,pandas-dev/pandas,datapythonista/pandas,pandas-dev/pandas,gfyoung/pandas,jreback/pandas,jreback/pandas,jorisvandenbossche/pandas,jorisvandenbossche/pandas,rs2/pandas,datapythonista/pandas,dsm054/pandas,jreback/pandas,dsm054/pandas,dsm054/pandas,rs2/pandas,jreback/pandas,datapythonista/pandas,pandas-dev/pandas