I need to find the specific week's start date and specific week's end date from previous year from the current date which differs with season.
If Season='Summer'
, get November 3rd Week
's start date and March 2nd Week
's end date.
If Season='Autumn'
, get March 3rd Week
's start date and June 2nd Week
's end date.
If Season='Winter'
, get June 3rd Week
's start date and November 2nd Week
's end date.
For Example:
If the current date is 14-12-2022
and Season='Summer'
, then the start date should be '15-11-2021'
and end date should be '12-03-2022'
.
How to achieve this in python? Like is there any datetime functions available ?