New coder developing script for use in my day job. Trying to make a class which take user entered month and year and combines them into date object. I can get the code for date entry and parsing into date object working. but then trying to make into a class so I can used over and over in difference instances which I cant seem to get right. I pasted where I currently am in my trial and error. I have been through many iterations trying to make it work. Any advice would be appreciated
```
class User_Input_Date():
def ini(self, month_input, year_input):
month_input = input('What was the month (1-12)')
if month_input in ['01', '1', 'Jan', 'January', 'jan', 'january']:
month_input = 1
return month_input
elif month_input in ['02', '2', 'Feb', 'February', 'feb', 'february']:
month_input = 2
return month_input
elif month_input in ['03', '3', 'Mar', 'March', 'mar', 'march']:
month_input = 3
return month_input
elif month_input in ['04', '4', 'Apr', 'April', 'apr', 'april']:
month_input = 4
return month_input
elif month_input in ['05', '5', 'May', 'may']:
month_input = 5
return month_input
elif month_input in ['06', '6', 'Jun', 'June', 'jun', 'june']:
month_input = 6
return month_input
elif month_input in ['07', '7', 'Jul', 'July', 'jul', 'july']:
month_input = 7
return month_input
elif month_input in ['08', '8', 'Aug', 'August', 'aug', 'august']:
month_input = 8
return month_input
elif month_input in ['09', '9', 'Sept', 'September', 'sept', 'september']:
month_input = 9
return month_input
elif month_input in ['10', 'Oct', 'October', 'oct', 'october']:
month_input = 10
return month_input
elif month_input in ['11', 'Nov', 'November', 'nov', 'november']:
month_input = 11
return month_input
elif month_input in ['12', 'Dec', 'December', 'dec', 'december']:
month_input = 12
return month_input
self.year_input = int(input('What was the year?'))
self.year_input = year_input
return year_input
def Combined_User_Input_Date(self, month_input, year_input):
combine_date_user_input_month_year = datetime.date(year, month, day=1)
return combine_date_user_input_month_year.strftime("%m" + "-" + "%Y")
primary_bariatric_date = User_Input_Date()
print(primary_bariatric_date.Combined_User_Input_Date())```